search for: tcsadrain

Displaying 6 results from an estimated 6 matches for "tcsadrain".

2005 Oct 10
2
[Bug 1101] terminal allocation hangs ssh at a blocking tcsetattr (-t option)
...nokia.com I'm trying to use ppp over ssh as follows: # pppd passive pty "ssh -qtt remote.mine.nu pppd 192.168.10.1:192.168.10.2" The ssh process which is run as a child will try as a consequence of option -t will hang for ever in function enter_raw_mode / tcsetattr(fileno(stdin), TCSADRAIN, &tio) . I could avoid the problem with replacing TCSADRAIN with TCSANOW, not sure though what a proper fix would be for this. ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee.
2004 Nov 22
1
patch to fix non-echo tty on scp SIGINT
...pid = -1; +/* Save terminal state for restore on exit */ +static struct termios _saved_tio; + static void killchild(int signo) { if (do_cmd_pid > 1) kill(do_cmd_pid, signo); + /* restore the terminal to its original state */ + if (tcsetattr(fileno(stdin), TCSADRAIN, &_saved_tio) == -1) + perror("tcsetattr"); + _exit(1); } @@ -218,6 +225,11 @@ extern char *optarg; extern int optind; + if (tcgetattr(fileno(stdin), &_saved_tio) == -1) { + perror("tcgetattr"); +...
2000 Jan 27
1
Long awaited round 1 of NeXT patches.
...nt +tcsetattr(fd, opt, t) + int fd, opt; + const struct termios *t; +{ + struct termios localterm; + + if (opt & TCSASOFT) { + localterm = *t; + localterm.c_cflag |= CIGNORE; + t = &localterm; + } + switch (opt & ~TCSASOFT) { + case TCSANOW: + return (ioctl(fd, TIOCSETA, t)); + case TCSADRAIN: + return (ioctl(fd, TIOCSETAW, t)); + case TCSAFLUSH: + return (ioctl(fd, TIOCSETAF, t)); + default: + errno = EINVAL; + return (-1); + } +} + +int tcsetpgrp(int fd, pid_t pgrp) +{ + int s; + + s = pgrp; + return (ioctl(fd, TIOCSPGRP, &s)); +} + +pid_t tcgetpgrp(int fd) +{ + int s; + + if...
2013 Aug 02
3
[PATCH trivial] include: uapi: standard all files' macro prefix and suffix, excluding "linux/" sub-directory
...rmbits.h +++ b/include/uapi/asm-generic/termbits.h @@ -1,5 +1,5 @@ -#ifndef __ASM_GENERIC_TERMBITS_H -#define __ASM_GENERIC_TERMBITS_H +#ifndef _UAPI_ASM_GENERIC_TERMBITS_H +#define _UAPI_ASM_GENERIC_TERMBITS_H #include <linux/posix_types.h> @@ -196,4 +196,4 @@ struct ktermios { #define TCSADRAIN 1 #define TCSAFLUSH 2 -#endif /* __ASM_GENERIC_TERMBITS_H */ +#endif /* _UAPI_ASM_GENERIC_TERMBITS_H */ diff --git a/include/uapi/asm-generic/types.h b/include/uapi/asm-generic/types.h index bd39806..e11d0a3 100644 --- a/include/uapi/asm-generic/types.h +++ b/include/uapi/asm-generic/types.h @@...
2013 Aug 02
3
[PATCH trivial] include: uapi: standard all files' macro prefix and suffix, excluding "linux/" sub-directory
...rmbits.h +++ b/include/uapi/asm-generic/termbits.h @@ -1,5 +1,5 @@ -#ifndef __ASM_GENERIC_TERMBITS_H -#define __ASM_GENERIC_TERMBITS_H +#ifndef _UAPI_ASM_GENERIC_TERMBITS_H +#define _UAPI_ASM_GENERIC_TERMBITS_H #include <linux/posix_types.h> @@ -196,4 +196,4 @@ struct ktermios { #define TCSADRAIN 1 #define TCSAFLUSH 2 -#endif /* __ASM_GENERIC_TERMBITS_H */ +#endif /* _UAPI_ASM_GENERIC_TERMBITS_H */ diff --git a/include/uapi/asm-generic/types.h b/include/uapi/asm-generic/types.h index bd39806..e11d0a3 100644 --- a/include/uapi/asm-generic/types.h +++ b/include/uapi/asm-generic/types.h @@...
2013 Aug 02
3
[PATCH trivial] include: uapi: standard all files' macro prefix and suffix, excluding "linux/" sub-directory
...rmbits.h +++ b/include/uapi/asm-generic/termbits.h @@ -1,5 +1,5 @@ -#ifndef __ASM_GENERIC_TERMBITS_H -#define __ASM_GENERIC_TERMBITS_H +#ifndef _UAPI_ASM_GENERIC_TERMBITS_H +#define _UAPI_ASM_GENERIC_TERMBITS_H #include <linux/posix_types.h> @@ -196,4 +196,4 @@ struct ktermios { #define TCSADRAIN 1 #define TCSAFLUSH 2 -#endif /* __ASM_GENERIC_TERMBITS_H */ +#endif /* _UAPI_ASM_GENERIC_TERMBITS_H */ diff --git a/include/uapi/asm-generic/types.h b/include/uapi/asm-generic/types.h index bd39806..e11d0a3 100644 --- a/include/uapi/asm-generic/types.h +++ b/include/uapi/asm-generic/types.h @@...