lkml.org 
[lkml]   [2004]   [Nov]   [17]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateWed, 17 Nov 2004 11:20:55 +0100 (MET)
FromJan Engelhardt <>
SubjectRe: about /proc/*/stat
>If I look at /proc/meminfo, I see each number prefixed with a short
>identifying name. Looking at /proc/*/stat, however, I have to count
>fields to get to the field I want. I realise that it's probably not
>possible to change the format of this file (since it's read by
>ps(1), among others), but I wonder if you have any tools that parse
>it, similar to /proc/meminfo -- i.e. primarily for debugging?

fscanf(fp, "%d %d %d ... ", &status, &anotherthing,....)



Jan Engelhardt
-- 
Gesellschaft für Wissenschaftliche Datenverarbeitung
Am Fassberg, 37077 Göttingen, www.gwdg.de
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:08    [from the cache]
©2003-2008