idle time

Guy Harris guy at auspex.auspex.com
Sat Apr 20 04:35:29 AEST 1991


>	Try having a look at the modification times of the user's 
>	/dev/tty* file.

Try having a look at the *access* time instead; that's the way all the
programs *I* know of that find "idle time" do it (the theory is that
they want the *user's* idle time, i.e. the time since they last asked
the system to do something, and the access time on the tty device gets
updated whenever a "read()" completes on that device, i.e. when
something to read becomes available because the user typed it).



More information about the Comp.unix.questions mailing list