search for: c_lflag

Displaying 20 results from an estimated 31 matches for "c_lflag".

2001 Oct 31
2
OpenStep (NeXT) and TTY modes
OpenStep, apparently, does not initialize new pty/tty modes to a sane default. I'm thinking this code snippet, added to tty_parse_modes() before the for(;;) loop should suffice: #ifdef HAVE_NEXT tio.c_oflag |= ONLCR; tio.c_lflag |= ECHO; #endif /* HAVE_NEXT */ Also, I've noticed that "ssh -t next_host stty" gives different output than an interactive session to the same NeXT... I suspect that this means that the SSH client is sending a different set of tty modes to the sshd on the NeXT... Is that so? Does tha...
2001 Jun 28
1
`_POSIX_VDISABLE' undeclared
Dear developpers, I'm using OpenSSH_2.9p1 with prngd on my Sony NEWS-OS 4.2.1R. NEWS-OS 4.x is based on 4.3BSD and lack of many POSIX and ANSI features. Today I tried to make the latest openssh_cvs and got the following error, gcc -g -O2 -Wall -O -I. -I.. -I. -I./.. -I/usr/local/ssl/include -DHAVE_CONFIG_H -c readpassphrase.c readpassphrase.c: In function `readpassphrase':
2001 Oct 18
0
Patch for hanging ssh-add under Solaris CDE
...z, flags) const char *prompt; @@ -102,13 +96,13 @@ term.c_cc[VSTATUS] = _POSIX_VDISABLE; } #endif - (void)tcsetattr(input, _T_FLUSH, &term); + (void)tcsetattr(input, TCSANOW, &term); } if (!(flags & RPP_ECHO_ON)) { if (tcgetattr(input, &term) == 0 && (term.c_lflag & ECHO)) { echo = 1; term.c_lflag &= ~ECHO; - (void)tcsetattr(input, _T_FLUSH, &term); + (void)tcsetattr(input, TCSANOW, &term); } } @@ -141,7 +135,7 @@ if (status != _POSIX_VDISABLE) term.c_cc[VSTATUS] = status; #endif - (void)tcsetattr(input, _T_FLUSH,...
2002 May 09
4
make distprep broken?
Hello All, Doing a make distprep doesn't seem to work anymore: $ make -f Makefile.in distprep make: @SH@: Command not found make: *** [catman-do] Error 127 I've seen this on AIX & Redhat (gnu make) and Solaris (native make). I suspect this occurs on most platforms. Is this still the recommended way of autoreconf'ing CVS releases for building? -Daz.
2008 Jan 16
8
PATCH [xenconsoled]: makes pty slave raw early
Hi, on my system (Linux 2.6.18.8 - ia64), if a domain write on the xencons before xenconsole is initialized the domain gets back what it wrote. This patch fixes this issue by making raw the pty slave very early. (I suppose it doesn''t happen with linux as a guest because it takes a little bit of time before writing to xencons). Tristan. _______________________________________________
2012 Dec 07
0
Rsync / ssh high cpu load
...-f -- /yyy/zzz.sql # strace -fF -v -p 29297 Process 29297 attached - interrupt to quit --- SIGTTOU (Stopped (tty output)) @ 0 (0) --- rt_sigreturn(0x16) = -1 EINTR (Interrupted system call) ioctl(4, SNDCTL_TMR_CONTINUE or TCSETSF, {c_iflags=0x500, c_oflags=0x5, c_cflags=0xbf, c_lflags=0x8a3b, c_line=0, c_cc="\x03\x1c\x7f\x15\x04\x00\x01\x00\x11\x13\x1a\x00\x12\x0f\x17\x16\x00\x00\x00"}) = ? ERESTARTSYS (To be restarted) --- SIGTTOU (Stopped (tty output)) @ 0 (0) --- rt_sigreturn(0x16) = -1 EINTR (Interrupted system call) ioctl(4, SNDCTL_TMR_CONTIN...
2009 Feb 15
2
COM32 module: Read-Only shell
...ing on. It's functional but still quite rough. My primary intention of posting it at this time is such that people have an easy way to demonstrate to themselves that the library calls I made work. This should apply as a patch to the head of the "dir" branch and the patch for c_cflag/c_lflag. The patch is only needed for Linux(without it, segfaults will occur). I've designed it to compile as a COM32 module and Linux binary when using GNU C (as Syslinux currently requires GNU C, if I read the Makefiles correctly). -- -Gene "No one ever says, 'I can't read that ASCI...
2020 Jun 01
0
[PATCH nbdkit 1/3] server: Disallow password=- from non-tty and fix error message (RHBZ#1842440).
...stdin is not available for reading password"); + if (read_password_interactive (password) == -1) return -1; - } - - printf ("password: "); - - /* Set no echo. */ - tty = isatty (0); - if (tty) { - tcgetattr (0, &orig); - temp = orig; - temp.c_lflag &= ~ECHO; - tcsetattr (0, TCSAFLUSH, &temp); - } - - r = getline (password, &n, stdin); - err = errno; - - /* Restore echo. */ - if (tty) - tcsetattr (0, TCSAFLUSH, &orig); - - /* Complete the printf above. */ - printf ("\n"); - - if (r ==...
2019 Jan 25
0
[klibc:update-dash] input: Remove HETIO
...t_term) - tcsetattr(1, TCSANOW, &old_term); -} - - -void setIO(struct termios *new, struct termios *old) /* Set terminal IO to canonical mode, and save old term settings. */ -{ - tcgetattr(0, old); - memcpy(new, old, sizeof(*new)); - new->c_cc[VMIN] = 1; - new->c_cc[VTIME] = 0; - new->c_lflag &= ~ICANON; /* unbuffered input */ - new->c_lflag &= ~ECHO; - tcsetattr(0, TCSANOW, new); -} - -void input_home(int *cursor) /* Command line input routines */ -{ - while (*cursor > 0) { - out1c('\b'); - --*cursor; - } - flushout(out1); -} - - -void input_delete(int curso...
2020 Mar 28
0
[klibc:update-dash] dash: input: Remove HETIO
...t_term) - tcsetattr(1, TCSANOW, &old_term); -} - - -void setIO(struct termios *new, struct termios *old) /* Set terminal IO to canonical mode, and save old term settings. */ -{ - tcgetattr(0, old); - memcpy(new, old, sizeof(*new)); - new->c_cc[VMIN] = 1; - new->c_cc[VTIME] = 0; - new->c_lflag &= ~ICANON; /* unbuffered input */ - new->c_lflag &= ~ECHO; - tcsetattr(0, TCSANOW, new); -} - -void input_home(int *cursor) /* Command line input routines */ -{ - while (*cursor > 0) { - out1c('\b'); - --*cursor; - } - flushout(out1); -} - - -void input_delete(int curso...
2002 Jun 21
0
[Bug 282] New: ttymodes sent can be invalid
...des for the terminal. */ if (tcsetattr(fd, TCSANOW, &tio) == -1) { log("Setting tty modes failed: %.100s", strerror(errno)); log("failed..: %d, %d, %d, %d, %d", fd, tio.c_iflag, tio.c_oflag, tio.c_cflag, tio.c_lflag); } And notice that the system logged the following the next time through: Setting tty modes failed: Invalid argument failed..: 10, 1280, 5, 447, 51771 and tried again and only the fd changed: Setting tty modes failed: Invalid argument failed..: 8, 1280, 5, 447, 51771...
2004 Aug 27
0
Terminal modes
...h server, setting some terminal modes, and they don't seem to do what I want. Specifically, I'm trying to disable echo from the server - hence the four modes in the sshd trace below (53 for example is ECHO). I've looked at the code. 0 would indicate that the option is negated in the c_lflag field. And it seems like the modes are applied to the pty successfully (else one would get an error: Setting tty modes failed: ) ... Yet I still get input echoed on the session. Any ideas? Are these modes not doing what I would expect them to do? Glen Matthews -------server trace extract---------...
2004 Aug 31
0
Terminal mode (repost)
...and setting some terminal modes. However, they don't seem to do what I want. Specifically, I'm trying to disable echo from the server - hence the four modes in the sshd trace below (53 for example is ECHO). I've looked at the code. 0 would indicate that the option is negated in the c_lflag field. And it seems like the modes are applied to the pty successfully (else one would get an error: Setting tty modes failed: ) ... Yet I still get input echoed on the session. Any ideas? Are these modes not doing what I would expect them to do? Glen Matthews -------server trace extract---------...
2008 Nov 25
1
sio vs uart vs ucomm problems / differences
..."(%s) %s:%d: open_dev", dev->name, __FILE__, __LINE__); } if (tcgetattr(dev->fd, &t) >= 0) { t.c_ispeed = dev->speed; t.c_ospeed = dev->speed; t.c_lflag &= ~(ICANON | ISIG | IEXTEN | ECHO | ECHOE | ECHOK | ECHOKE | ECHONL | ECHOCTL | ECHOPRT | ALTWERASE | NOFLSH | TOSTOP | FLUSHO | PENDIN | NOKERNINFO | EXTPROC); t.c_iflag &= ~(ISTRIP | ICRNL | INLCR | IGNCR | IXON | IXOFF | IXANY | IMAXBEL | IGNBRK | BRKINT | INPCK | IGNPAR...
2020 Jun 01
7
server: Fix reading passwords interactively.
https://bugzilla.redhat.com/show_bug.cgi?id=1842440 Patches 1 and 2 address fairly obvious bugs in how we handle reading passwords from stdin. There are other ways we may consider fixing these bugs: - Should password=- always open /dev/tty and ignore stdin entirely? - Should we make password=-0/-1/-2 work by skipping the close? Or perhaps reopen the file descriptors on /dev/null after
2002 Feb 12
1
SSH Client Hangs after logging in to SSHD
I'm not a ssh expert and I don't know if the log is good or bad, but I too am running OpenSHH under OpenServer. I find that after I connect, the return key has no effect unless I first type: stty sane <Ctrl>j If you've hit <ENTER> before that you must first press <Ctrl>j a couple of times to clean out the buffer. After I type the above command, everything
2020 Mar 26
0
[PATCH nbdkit 5/9 patch split 2/5] lib: Move code for parsing, passwords and paths into libnbdkit.so.
...g, temp; - ssize_t r; - size_t n; - - *password = NULL; - - /* Read from stdin. */ - if (strcmp (value, "-") == 0) { - printf ("password: "); - - /* Set no echo. */ - tty = isatty (0); - if (tty) { - tcgetattr (0, &orig); - temp = orig; - temp.c_lflag &= ~ECHO; - tcsetattr (0, TCSAFLUSH, &temp); - } - - r = getline (password, &n, stdin); - err = errno; - - /* Restore echo. */ - if (tty) - tcsetattr (0, TCSAFLUSH, &orig); - - /* Complete the printf above. */ - printf ("\n"); - - if (r ==...
2001 Oct 12
17
Please test snapshots for 3.0 release
Could everyone please test the latest snapshots as we will be making a new release soon. If you have any patches you would like us to consider, please resend them to the list ASAP. -d -- | Damien Miller <djm at mindrot.org> \ ``E-mail attachments are the poor man's | http://www.mindrot.org / distributed filesystem'' - Dan Geer
2000 Jan 27
1
Long awaited round 1 of NeXT patches.
...ode: character-at-a-time + * mode with no characters interpreted, 8-bit data path. + */ +void +cfmakeraw(t) + struct termios *t; +{ + + t->c_iflag &= +~(IMAXBEL|IXOFF|INPCK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON|IGNPAR); + t->c_iflag |= IGNBRK; + t->c_oflag &= ~OPOST; + t->c_lflag &= +~(ECHO|ECHOE|ECHOK|ECHONL|ICANON|ISIG|IEXTEN|NOFLSH|TOSTOP|PENDIN); + t->c_cflag &= ~(CSIZE|PARENB); + t->c_cflag |= CS8|CREAD; + t->c_cc[VMIN] = 1; + t->c_cc[VTIME] = 0; +} + +int +tcsendbreak(fd, len) + int fd, len; +{ + struct timeval sleepytime; + + sleepytime.tv_sec =...
2009 Jan 26
1
ups emerson liebert GTX2 ESP-II serial protocol demo
...rrno); } tcgetattr(fd,&oldtio); /* save current port settings */ bzero(&newtio, sizeof(newtio)); newtio.c_cflag = BAUDRATE /*| CRTSCTS*/ | CS8 | CLOCAL | CREAD; newtio.c_iflag = IGNPAR | IGNBRK; newtio.c_oflag = 0; /* set input mode (non-canonical, no echo,...) */ newtio.c_lflag = 0; newtio.c_cc[VTIME] = 0; /* inter-character timer unused */ newtio.c_cc[VMIN] = 1; /* blocking read until 5 chars received */ tcflush(fd, TCIFLUSH); tcsetattr(fd,TCSANOW,&newtio); signal( SIGALRM, &sgnl_ignore ); while (1) { for (i=0;i<ncmd;i++) { //pri...