[prev in list] [next in list] [prev in thread] [next in thread]
List: hpux-devtools
Subject: RE: HPUX-DEVTOOLS: Number of open files in a process
From: Mike Stroyan <stroyan () hpstryn ! fc ! hp ! com>
Date: 2001-04-30 17:06:10
[Download RAW message or body]
| Yes, thank you very much.
| But in HP-UX 11.0, the element can not be set to zero, since only one will
| be returned by "pstat_getfile". It can be set to the number of maximum
| permissible number of open files give by "get_rlimit".
I was actually referring to only pstat_getproc() when describing how to
pass an elemcount of zero and an index of a particular pid. pstat_getfile()
always refers to only one process at a time.
The pstat man page does describe a way to call pstat_getfile() with an
elemcount of zero to get information about a particular file descriptor.
That is not suited to your task.
Note that you need to allocate a buffer as big as the elemcount that you
pass in. If you use the getrlimit() rlim_max value then you will need to
dynamically allocate a buf big enough to hold that many pst_fileinfo structs.
Mike Stroyan, mike_stroyan@fc.hp.com
_________________________________________________________________
To leave this mailing list, send mail to majordomo@cxx.cup.hp.com
with the message UNSUBSCRIBE hpux-devtools
_________________________________________________________________
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic