]> git.ipfire.org Git - thirdparty/util-linux.git/commit
lib: [procutils.c]: general purpose procfs parsing functions
authorDavidlohr Bueso <dave@gnu.org>
Tue, 3 May 2011 18:57:01 +0000 (15:57 -0300)
committerKarel Zak <kzak@redhat.com>
Wed, 4 May 2011 13:30:28 +0000 (15:30 +0200)
commit9734045d9d11330b7782fbcffccf74fc98cdcc5c
tree54e0d01072a3242e8600d8ab22ffe243bbb89e0a
parent9fae6c27d37b7da4770ef175579b3327fb2a2165
lib: [procutils.c]: general purpose procfs parsing functions

We include the following functions as a first approach:

  - proc_open_tasks(): allocate resources and setup basic data
  - proc_next_tid(): iterate over the thread group
  - proc_close_tasks(): free used resources

[kzak@redhat.com: - free() on error in proc_open_tasks(),
                  - always call free() in proc_close_tasks()
                  - ignore non-digit dirs and return 1 on end-of-dir
                    in proc_next_tid()]

Signed-off-by: Davidlohr Bueso <dave@gnu.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
lib/Makefile.am