Home
last modified time | relevance | path

Searched refs:tty (Results 1 – 25 of 245) sorted by relevance

12345678910

/third_party/weston/libweston/
Dlauncher-direct.c96 int kb_mode, tty, drm_fd; member
110 ioctl(launcher->tty, VT_RELDISP, 1); in vt_handler()
112 ioctl(launcher->tty, VT_RELDISP, VT_ACKACQ); in vt_handler()
122 setup_tty(struct launcher_direct *launcher, int tty) in setup_tty() argument
130 if (tty == 0) { in setup_tty()
131 launcher->tty = dup(tty); in setup_tty()
132 if (launcher->tty == -1) { in setup_tty()
138 snprintf(tty_device, sizeof tty_device, "/dev/tty%d", tty); in setup_tty()
139 launcher->tty = open(tty_device, O_RDWR | O_CLOEXEC); in setup_tty()
140 if (launcher->tty == -1) { in setup_tty()
[all …]
Dweston-launch.c105 int tty; member
219 err = pam_set_item(wl->ph, PAM_TTY, ttyname(wl->tty)); in setup_pam()
452 ioctl(wl->tty, VT_RELDISP, 1); in handle_socket_msg()
486 oldtty = wl->tty; in quit()
487 wl->tty = open_tty_by_number(wl->ttynr); in quit()
490 if (ioctl(wl->tty, KDSKBMUTE, 0) && in quit()
491 ioctl(wl->tty, KDSKBMODE, wl->kb_mode)) in quit()
495 if (ioctl(wl->tty, KDSETMODE, KD_TEXT)) in quit()
505 if (ioctl(wl->tty, VT_SETMODE, &mode) < 0) in quit()
508 if (wl->tty != STDIN_FILENO) in quit()
[all …]
Dlauncher-weston-launch.c95 int kb_mode, tty, drm_fd; member
181 if (ioctl(launcher->tty, KDSKBMUTE, 0) && in launcher_weston_launch_restore()
182 ioctl(launcher->tty, KDSKBMODE, launcher->kb_mode)) in launcher_weston_launch_restore()
186 if (ioctl(launcher->tty, KDSETMODE, KD_TEXT)) in launcher_weston_launch_restore()
196 if (ioctl(launcher->tty, VT_SETMODE, &mode) < 0) in launcher_weston_launch_restore()
246 return ioctl(launcher->tty, VT_ACTIVATE, vt); in launcher_weston_launch_activate_vt()
272 int tty, const char *seat_id, bool sync_drm) in launcher_weston_launch_connect() argument
287 launcher->tty = launcher_weston_environment_get_fd("WESTON_TTY_FD"); in launcher_weston_launch_connect()
321 if (launcher->tty >= 0) in launcher_weston_launch_destroy()
322 close(launcher->tty); in launcher_weston_launch_destroy()
[all …]
/third_party/libuv/src/win/
Dtty.c190 int uv_tty_init(uv_loop_t* loop, uv_tty_t* tty, uv_file fd, int unused) { in uv_tty_init() argument
249 uv__stream_init(loop, (uv_stream_t*) tty, UV_TTY); in uv_tty_init()
250 uv__connection_init((uv_stream_t*) tty); in uv_tty_init()
252 tty->handle = handle; in uv_tty_init()
253 tty->u.fd = fd; in uv_tty_init()
254 tty->reqs_pending = 0; in uv_tty_init()
255 tty->flags |= UV_HANDLE_BOUND; in uv_tty_init()
259 tty->flags |= UV_HANDLE_TTY_READABLE | UV_HANDLE_READABLE; in uv_tty_init()
261 tty->tty.rd.unused_ = NULL; in uv_tty_init()
262 tty->tty.rd.read_line_buffer = uv_null_buf_; in uv_tty_init()
[all …]
/third_party/node/test/pseudo-tty/
Dtest-handle-wrap-isrefed-tty.js9 const tty = new ReadStream(0); constant
13 strictEqual(tty._handle.hasRef(),
15 tty.unref();
16 strictEqual(tty._handle.hasRef(),
18 tty.ref();
19 strictEqual(tty._handle.hasRef(),
21 tty._handle.close(common.mustCall(() =>
22 strictEqual(tty._handle.hasRef(),
/third_party/eudev/rules/
D50-udev-default.rules18 SUBSYSTEM=="tty", KERNEL=="ptmx", GROUP="tty", MODE="0666"
19 SUBSYSTEM=="tty", KERNEL=="tty", GROUP="tty", MODE="0666"
20 SUBSYSTEM=="tty", KERNEL=="tty[0-9]*", GROUP="tty", MODE="0620"
21 SUBSYSTEM=="tty", KERNEL=="sclp_line[0-9]*", GROUP="tty", MODE="0620"
22 SUBSYSTEM=="tty", KERNEL=="ttysclp[0-9]*", GROUP="tty", MODE="0620"
23 SUBSYSTEM=="tty", KERNEL=="3270/tty[0-9]*", GROUP="tty", MODE="0620"
24 SUBSYSTEM=="vc", KERNEL=="vcs*|vcsa*", GROUP="tty"
25 KERNEL=="tty[A-Z]*[0-9]|ttymxc[0-9]*|pppox[0-9]*|ircomm[0-9]*|noz[0-9]*|rfcomm[0-9]*", GROUP="dialo…
/third_party/node/test/async-hooks/
Dtest-ttywrap.readstream.js27 const tty = activities[0]; constant
28 assert.strictEqual(tty.type, 'TTYWRAP');
29 assert.strictEqual(typeof tty.uid, 'number');
30 assert.strictEqual(typeof tty.triggerAsyncId, 'number');
31 checkInvocations(tty, checkInitOpts, 'when tty created');
34 checkInvocations(tty, checkEndedOpts, 'when tty ended');
41 checkInvocations(tty, checkInitOpts, 'when tty.end() was invoked');
46 checkInvocations(tty, checkEndedOpts, 'when process exits');
/third_party/libuv/src/unix/
Dtty.c123 int uv_tty_init(uv_loop_t* loop, uv_tty_t* tty, int fd, int unused) { in uv_tty_init() argument
197 uv__stream_init(loop, (uv_stream_t*) tty, UV_TTY); in uv_tty_init()
207 r = uv__stream_try_select((uv_stream_t*) tty, &fd); in uv_tty_init()
212 QUEUE_REMOVE(&tty->handle_queue); in uv_tty_init()
225 uv__stream_open((uv_stream_t*) tty, fd, flags); in uv_tty_init()
226 tty->mode = UV_TTY_MODE_NORMAL; in uv_tty_init()
268 int uv_tty_set_mode(uv_tty_t* tty, uv_tty_mode_t mode) { in uv_tty_set_mode() argument
272 if (tty->mode == (int) mode) in uv_tty_set_mode()
275 fd = uv__stream_fd(tty); in uv_tty_set_mode()
276 if (tty->mode == UV_TTY_MODE_NORMAL && mode != UV_TTY_MODE_NORMAL) { in uv_tty_set_mode()
[all …]
/third_party/libuv/test/
Dtest-handle-fileno.c54 uv_tty_t tty; in TEST_IMPL() local
108 r = uv_tty_init(loop, &tty, tty_fd, 0); in TEST_IMPL()
110 ASSERT(uv_is_readable((uv_stream_t*) &tty)); in TEST_IMPL()
111 ASSERT(!uv_is_writable((uv_stream_t*) &tty)); in TEST_IMPL()
112 r = uv_fileno((uv_handle_t*) &tty, &fd); in TEST_IMPL()
114 uv_close((uv_handle_t*) &tty, NULL); in TEST_IMPL()
115 r = uv_fileno((uv_handle_t*) &tty, &fd); in TEST_IMPL()
117 ASSERT(!uv_is_readable((uv_stream_t*) &tty)); in TEST_IMPL()
118 ASSERT(!uv_is_writable((uv_stream_t*) &tty)); in TEST_IMPL()
Dtest-osx-select.c55 uv_tty_t tty; in TEST_IMPL() local
64 r = uv_tty_init(uv_default_loop(), &tty, fd, 1); in TEST_IMPL()
67 uv_read_start((uv_stream_t*) &tty, alloc_cb, read_cb); in TEST_IMPL()
94 uv_tty_t tty; in TEST_IMPL() local
117 r = uv_tty_init(uv_default_loop(), &tty, fd, 1); in TEST_IMPL()
120 r = uv_read_start((uv_stream_t*) &tty, alloc_cb, read_cb); in TEST_IMPL()
Dtest-tty.c44 TEST_IMPL(tty) { in TEST_IMPL() argument
352 uv_tty_t tty; in TEST_IMPL() local
361 ASSERT(UV_EINVAL == uv_tty_init(&loop, &tty, fd, 1)); in TEST_IMPL()
364 ASSERT(UV_EINVAL == uv_tty_init(&loop, &tty, fd, 1)); in TEST_IMPL()
371 ASSERT(UV_EINVAL == uv_tty_init(&loop, &tty, fd, 1)); in TEST_IMPL()
378 ASSERT(UV_EINVAL == uv_tty_init(&loop, &tty, fd, 1)); in TEST_IMPL()
384 ASSERT(0 == uv_tty_init(&loop, &tty, fd, 1)); in TEST_IMPL()
386 ASSERT(uv_is_readable((uv_stream_t*) &tty)); in TEST_IMPL()
387 ASSERT(uv_is_writable((uv_stream_t*) &tty)); in TEST_IMPL()
388 uv_close((uv_handle_t*) &tty, NULL); in TEST_IMPL()
[all …]
/third_party/python/Lib/test/
Dtest_ioctl.py11 tty = open("/dev/tty", "rb") variable
15 with tty:
17 r = fcntl.ioctl(tty, termios.TIOCGPGRP, " ")
22 del tty, r, rpgrp
34 with open("/dev/tty", "rb") as tty:
35 r = fcntl.ioctl(tty, termios.TIOCGPGRP, " ")
51 with open("/dev/tty", "rb") as tty:
52 r = fcntl.ioctl(tty, termios.TIOCGPGRP, buf, True)
Dtest_pty.py10 import tty
19 import tty
27 _TIOCGWINSZ = tty.TIOCGWINSZ
28 _TIOCSWINSZ = tty.TIOCSWINSZ
79 tty.tcgetattr(pty.STDIN_FILENO)
81 except tty.error:
132 mode = tty.tcgetattr(pty.STDIN_FILENO)
133 except tty.error:
182 self.assertEqual(tty.tcgetattr(slave_fd), mode,
/third_party/libuv/docs/code/tty/
Dmain.c7 uv_tty_t tty; variable
11 uv_tty_init(loop, &tty, STDOUT_FILENO, 0); in main()
12 uv_tty_set_mode(&tty, UV_TTY_MODE_NORMAL); in main()
19 uv_write(&req, (uv_stream_t*) &tty, &buf, 1, NULL); in main()
26 uv_write(&req, (uv_stream_t*) &tty, &buf, 1, NULL); in main()
/third_party/node/test/parallel/
Dtest-ttywrap-invalid-fd.js5 const tty = require('tty'); constant
14 () => new tty.WriteStream(-1),
37 new tty.WriteStream(fd);
50 new tty.ReadStream(fd);
61 () => new tty.ReadStream(-1),
Dtest-net-access-byteswritten.js10 const tty = require('tty'); constant
18 assert.strictEqual(Object.getPrototypeOf(tty.ReadStream).prototype.bytesWritten,
20 assert.strictEqual(tty.ReadStream.prototype.bytesWritten, undefined);
21 assert.strictEqual(tty.WriteStream.prototype.bytesWritten, undefined);
/third_party/libuv/docs/code/tty-gravity/
Dmain.c7 uv_tty_t tty; variable
23 uv_write(&write_req, (uv_stream_t*) &tty, &buf, 1, NULL); in update()
35 uv_tty_init(loop, &tty, STDOUT_FILENO, 0); in main()
36 uv_tty_set_mode(&tty, 0); in main()
38 if (uv_tty_get_winsize(&tty, &width, &height)) { in main()
/third_party/toybox/toys/posix/
Dtty.c27 char *tty = ttyname(0); in tty_main() local
29 if (!toys.optflags) puts(tty ? tty : "not a tty"); in tty_main()
31 toys.exitval = !tty; in tty_main()
Dxargs.c44 FILE *tty;
176 if (!TT.tty) TT.tty = xfopen("/dev/tty", "re"); in xargs_main()
177 if (!fyesno(TT.tty, 0)) goto skip; in xargs_main()
215 if (TT.tty) fclose(TT.tty); in xargs_main()
/third_party/python/Doc/library/
Dtty.rst1 :mod:`tty` --- Terminal control functions
4 .. module:: tty
11 **Source code:** :source:`Lib/tty.py`
15 The :mod:`tty` module defines functions for putting the tty into cbreak and raw
20 The :mod:`tty` module defines the following functions:
Dtermios.rst1 :mod:`termios` --- POSIX style tty control
6 :synopsis: POSIX style tty control.
10 pair: tty; I/O control
14 This module provides an interface to the POSIX calls for tty I/O control. For a
17 *termios* style tty I/O control configured during installation.
33 Return a list containing the tty attributes for file descriptor *fd*, as
35 list of the tty special characters (each a string of length 1, except the
44 Set the tty attributes for file descriptor *fd* from the *attributes*, which is
79 Module :mod:`tty`
90 :keyword:`finally` statement to ensure that the old tty attributes are restored
/third_party/toybox/toys/other/
Dlogin.c41 int hh = FLAG(h), count, tty = tty_fd(); in login_main() local
46 if (tty == -1) error_exit("no tty"); in login_main()
96 ttyname(tty), hh ? "from " : "", hh ? TT.h : ""); in login_main()
119 if (fchown(tty, pwd->pw_uid, pwd->pw_gid) || fchmod(tty, 0600)) in login_main()
128 ttyname(tty), hh ? "from" : "", hh ? TT.h : ""); in login_main()
/third_party/node/doc/api/
Dtty.md7 <!-- source_link=lib/tty.js -->
9 The `tty` module provides the `tty.ReadStream` and `tty.WriteStream` classes.
14 const tty = require('tty');
19 `tty.ReadStream` and both [`process.stdout`][] and [`process.stderr`][] will, by
20 default, be instances of `tty.WriteStream`. The preferred method of determining
32 manually create instances of the `tty.ReadStream` and `tty.WriteStream`
35 ## Class: `tty.ReadStream`
43 [`process.stdin`][] will be the only `tty.ReadStream` instance in a Node.js
59 A `boolean` that is always `true` for `tty.ReadStream` instances.
66 * `mode` {boolean} If `true`, configures the `tty.ReadStream` to operate as a
[all …]
/third_party/openssl/crypto/ui/
Dui_openssl.c114 # define TTY_get(tty,data) tcgetattr(tty,data) argument
115 # define TTY_set(tty,data) tcsetattr(tty,TCSANOW,data) argument
122 # define TTY_get(tty,data) ioctl(tty,TCGETA,data) argument
123 # define TTY_set(tty,data) ioctl(tty,TCSETA,data) argument
130 # define TTY_get(tty,data) ioctl(tty,TIOCGETP,data) argument
131 # define TTY_set(tty,data) ioctl(tty,TIOCSETP,data) argument
191 static int noecho_fgets(char *buf, int size, FILE *tty);
682 static int noecho_fgets(char *buf, int size, FILE *tty) in noecho_fgets() argument
/third_party/node/lib/
Dtty.js54 const tty = new TTY(fd, true, ctx);
63 handle: tty,
92 const tty = new TTY(fd, false, ctx);
98 handle: tty,

12345678910