diff options
| author | David E. O'Brien <obrien@FreeBSD.org> | 2000-12-11 01:03:42 +0000 |
|---|---|---|
| committer | David E. O'Brien <obrien@FreeBSD.org> | 2000-12-11 01:03:42 +0000 |
| commit | 6034d13a9ed650ee88ae94550adc86ef25441310 (patch) | |
| tree | 6e0c502d67cc546866c1072128e560fd9249bc3f /gnu/usr.bin/patch | |
| parent | b67b2ea4cec679f2f5c3a7bd797837b22b8c9387 (diff) | |
Notes
Diffstat (limited to 'gnu/usr.bin/patch')
| -rw-r--r-- | gnu/usr.bin/patch/util.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/gnu/usr.bin/patch/util.c b/gnu/usr.bin/patch/util.c index 258490bcb8f3..277440ca0ac1 100644 --- a/gnu/usr.bin/patch/util.c +++ b/gnu/usr.bin/patch/util.c @@ -1,3 +1,7 @@ +/* $FreeBSD$ */ + +#include <paths.h> + #include "EXTERN.h" #include "common.h" #include "INTERN.h" @@ -247,7 +251,7 @@ long arg1,arg2,arg3; write(1, buf, strlen(buf)); r = read(1, buf, sizeof buf); } - else if ((ttyfd = open("/dev/tty", 2)) >= 0 && isatty(ttyfd)) { + else if ((ttyfd = open(_PATH_TTY, 2)) >= 0 && isatty(ttyfd)) { /* might be deleted or unwriteable */ write(ttyfd, buf, strlen(buf)); r = read(ttyfd, buf, sizeof buf); @@ -382,7 +386,7 @@ int assume_exists; if (debug & 128) say4("fetchname %s %d %d\n",at,strip_leading,assume_exists); #endif - if (strnEQ(at, "/dev/null", 9)) /* so files can be created by diffing */ + if (strnEQ(at, _PATH_DEVNULL, sizeof _PATH_DEVNULL - 1)) /* so files can be created by diffing */ return Nullch; /* against /dev/null. */ name = fullname = t = savestr(at); |
