Skip to contentSkip to conversation

just curious!

DISCUSSION Suma Choudhary 1 participant 1 message Oct 10, 2005

lore
Share & tools
lore
#0 lore raw

Thanks a lot.....

I got to know about the utmp file and the terminal device from the strace and ltrace as suggested by David Eduardo.Could even write a small code to emulate "write".

Didnt know about "mesg" though.

Thanks again
suma

Quoted 1 line
Quoted 1 line
Quoted 1 line

Glynn Clements <[email protected]> 10/08/05 12:54 PM >>>

Quoted 1 line · Suma Choudhary

I was curious to know how the "write" command works.Any IPCs used?

It determines the terminal(s) on which the specified user is logged in from the utmp file, opens the terminal device for writing, and writes to it.

Note that the terminal device must be group-writeable (normally controlled using "mesg y" or "mesg n"). The write command itself is setgid tty.

Signature · 5 lines
Glynn Clements <[email protected]>
-
To unsubscribe from this list: send the line "unsubscribe linux-c-programming" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html