processes plugin: Fix handling of Linux 2.4.
authorAndrés J. Díaz <ajdiaz@connectical.com>
Sat, 19 Sep 2009 06:45:49 +0000 (08:45 +0200)
committerFlorian Forster <octo@leeloo.lan.home.verplant.org>
Sat, 19 Sep 2009 06:47:50 +0000 (08:47 +0200)
commite75f137bdc3f6a002a8b31d822f7732e191c0f2b
tree4e5b4bb732ce9a556a90f1405fb08c831e87d82d
parent0f7c2b6ac38ad09ac767fe745737035acc22906e
processes plugin: Fix handling of Linux 2.4.

Hi Florian et al

Thanks for the reply, but we detect a minor bug in the previous patch
due to kernel 2.4

The correct patch is attached. The bug is related with kernels 2.4,
where task/ directory do not exists and ps_read_task return -1, which is
catched and raise an error (breaking the ps_read_process function), so a
NaN is dispatched istead of values (number of process:1, number of
threads :1).

Sorry for the inconvenience :(

Regards,
  Andres

Signed-off-by: Florian Forster <octo@leeloo.lan.home.verplant.org>
src/processes.c