From 3e2a8b618ac5078e449c69bfc430cdb7f53d9b6b Mon Sep 17 00:00:00 2001 From: Eric Andersen Date: Mon, 25 Mar 2002 19:40:43 +0000 Subject: Patch from Steven J. Hill to disable __fsetlocking when threads are disabled. Bug is my fault. oops. -Erik --- libc/misc/ttyent/getttyent.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libc/misc/ttyent') diff --git a/libc/misc/ttyent/getttyent.c b/libc/misc/ttyent/getttyent.c index 7784a6ab4..0df2b4a79 100644 --- a/libc/misc/ttyent/getttyent.c +++ b/libc/misc/ttyent/getttyent.c @@ -179,7 +179,9 @@ int setttyent(void) return (1); } else if ((tf = fopen(_PATH_TTYS, "r"))) { /* We do the locking ourselves. */ +#ifdef __UCLIBC_HAS_THREADS__ __fsetlocking (tf, FSETLOCKING_BYCALLER); +#endif return (1); } return (0); -- cgit v1.2.3