Thanks Ryan
 
Is there any way in Perl (pure way) wherein I can write onto utmpx or wtmpx to enter just a dummy message  with all the format of utmpx/wtmpx being compliant?
 
Regards.
Nikhil

 
On 10/20/05, Fintan Ryan <[EMAIL PROTECTED]> wrote:
Hi,

< Is it a system call ? if yess can I use that in my perl code from syscall
< function ? , or is there any perl equivalent ?

       Its a function in libc.

       There is a perl module call Time::HR which you can
       get from CPAN, which works fine.

       A cursory check with syscall(&SYS_gethrtime, $hrtime)
       fails, and even if it worked it would be messy (packing,
       unpacking and requiring h2ph to be run always seems like
       to much work).

< It would be even ok if we had any command line equivalent as well so that we
< can use even in any shell scripts too..

       literally just use

       hrtime_t t = gethrtime();

       in your c program and print out your result.

       For a commandline value I would recommend using the the
       kstat example as given by Dan, it is the number that all
       the other utilities will be using.

- Fintan
--
[EMAIL PROTECTED]   http://blogs.sun.com/fintanr
@dub03              http://www.opensolaris.org

_______________________________________________
opensolaris-code mailing list
[email protected]
https://opensolaris.org:444/mailman/listinfo/opensolaris-code

Reply via email to