diff options
author | Jeff Johnston <jjohnstn@redhat.com> | 2000-08-24 22:32:38 +0000 |
---|---|---|
committer | Jeff Johnston <jjohnstn@redhat.com> | 2000-08-24 22:32:38 +0000 |
commit | 2d5862dee6b6acd965d93f39eed737e67863a34e (patch) | |
tree | 5a090bd5ab4f8ac0454daeb3c57e19152b3b8e09 /newlib/libc/unix | |
parent | de43b06d7bd1d2e3f5472681732b39c46edd4ae4 (diff) | |
download | cygnal-2d5862dee6b6acd965d93f39eed737e67863a34e.tar.gz cygnal-2d5862dee6b6acd965d93f39eed737e67863a34e.tar.bz2 cygnal-2d5862dee6b6acd965d93f39eed737e67863a34e.zip |
2000-08-23 Werner Almesberger <Werner.Almesberger@epfl.ch>
* libc/stdlib/mprec.c (ulp, b2d, d2b): changed a few expressions
like x << y-z to the equivalent x << (y-z).
(d2b): changed if statements with assignment to perform the
assignment prior to the if check.
* libc/reent/reent.c: included stdlib.h for "_free_r" prototype.
* libc/unix/getpass.c (getpass): moved "echo" assignment out of if.
* libc/unix/ttyname.c: included string.h for "strcpy" prototype.
* libc/unix/getcwd.c (ISDOT): added parentheses to clarify && and ||
precedence.
* libc/include/sys/unistd.h: added "vfork" prototype (for popen.c).
Added "_execve" prototype (for execl.c, execle.c, execv.c, and
execve.c).
* libc/posix/popen.c (popen): added parentheses to clarify && and ||
precedence.
* libm/math/e_cosh.c (__ieee754_cosh): changed parentheses to
clarify && and || precendence (and to remove pascalism).
* libm/math/e_sinh.c (__ieee754_sinh): Ditto.
* libm/math/s_infconst.c: added another pair of braces to all
initializers for __infinity (need three: for __infinity[1] array,
for union __dmath, and for i[2]).
Diffstat (limited to 'newlib/libc/unix')
-rw-r--r-- | newlib/libc/unix/getcwd.c | 2 | ||||
-rw-r--r-- | newlib/libc/unix/getpass.c | 3 | ||||
-rw-r--r-- | newlib/libc/unix/ttyname.c | 1 |
3 files changed, 4 insertions, 2 deletions
diff --git a/newlib/libc/unix/getcwd.c b/newlib/libc/unix/getcwd.c index ee53536ed..826fc789d 100644 --- a/newlib/libc/unix/getcwd.c +++ b/newlib/libc/unix/getcwd.c @@ -49,7 +49,7 @@ static char sccsid[] = "@(#)getcwd.c 5.11 (Berkeley) 2/24/91"; #define ISDOT(dp) \ (dp->d_name[0] == '.' && (dp->d_name[1] == '\0' || \ - dp->d_name[1] == '.' && dp->d_name[2] == '\0')) + (dp->d_name[1] == '.' && dp->d_name[2] == '\0'))) #ifndef _REENT_ONLY diff --git a/newlib/libc/unix/getpass.c b/newlib/libc/unix/getpass.c index ff9e7e67d..b45df074f 100644 --- a/newlib/libc/unix/getpass.c +++ b/newlib/libc/unix/getpass.c @@ -70,7 +70,8 @@ getpass (prompt) */ omask = sigblock (sigmask (SIGINT) | sigmask (SIGTSTP)); (void) tcgetattr (fileno (fp), &term); - if (echo = (term.c_lflag & ECHO)) + echo = (term.c_lflag & ECHO); + if (echo) { term.c_lflag &= ~ECHO; (void) tcsetattr (fileno (fp), TCSAFLUSH, &term); diff --git a/newlib/libc/unix/ttyname.c b/newlib/libc/unix/ttyname.c index 582a7903f..258ba25fe 100644 --- a/newlib/libc/unix/ttyname.c +++ b/newlib/libc/unix/ttyname.c @@ -41,6 +41,7 @@ static char sccsid[] = "@(#)ttyname.c 5.10 (Berkeley) 5/6/91"; #include <dirent.h> #include <termios.h> #include <unistd.h> +#include <string.h> #include <paths.h> #include <_syslist.h> |