diff options
Diffstat (limited to 'docs')
-rw-r--r-- | docs/ctty.htm | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/docs/ctty.htm b/docs/ctty.htm index 26d2c7956..b8bce003c 100644 --- a/docs/ctty.htm +++ b/docs/ctty.htm | |||
@@ -365,7 +365,7 @@ this is a great mystery. | |||
365 | becomes its controlling tty. | 365 | becomes its controlling tty. |
366 | </p><p>The BSD approach is that one has to explicitly call | 366 | </p><p>The BSD approach is that one has to explicitly call |
367 | </p><blockquote> | 367 | </p><blockquote> |
368 | <pre>ioctl(fd, TIOCSCTTY, ...); | 368 | <pre>ioctl(fd, TIOCSCTTY, 0/1); |
369 | </pre> | 369 | </pre> |
370 | </blockquote> | 370 | </blockquote> |
371 | 371 | ||
@@ -378,6 +378,8 @@ and (ii) it does not yet have a controlling tty, and | |||
378 | (iii) maybe the tty should not already control some other session; | 378 | (iii) maybe the tty should not already control some other session; |
379 | if it does it is an error if we aren't root, or we steal the tty | 379 | if it does it is an error if we aren't root, or we steal the tty |
380 | if we are all-powerful. | 380 | if we are all-powerful. |
381 | [vda: correction: third parameter controls this: if 1, we steal tty from | ||
382 | any such session, if 0, we don't steal] | ||
381 | </p><p>Opening some terminal will give us a controlling tty, | 383 | </p><p>Opening some terminal will give us a controlling tty, |
382 | provided that (i) the current process is a session leader, and | 384 | provided that (i) the current process is a session leader, and |
383 | (ii) it does not yet have a controlling tty, and | 385 | (ii) it does not yet have a controlling tty, and |