fix Pid.PidFile

This commit is contained in:
Doug MacEachern 2007-08-10 02:45:11 +00:00
parent eec869f6d7
commit c7089edade
1 changed files with 2 additions and 2 deletions

View File

@ -686,8 +686,8 @@ static int ptql_pid_get(sigar_t *sigar,
if (status != SIGAR_OK) {
return status;
}
*pid = strtoull(buffer, &ptr, 10);
if (strtonum_failed(buffer, ptr)) {
*pid = str2pid(buffer, ptr);
if ((buffer == ptr) || (errno == ERANGE)) {
return errno;
}
}