move stdio locking MAYBE_WAITERS definition to stdio_impl.h
authorRich Felker <dalias@aerifal.cx>
Tue, 16 Oct 2018 04:59:43 +0000 (00:59 -0400)
committerRich Felker <dalias@aerifal.cx>
Tue, 16 Oct 2018 17:50:27 +0000 (13:50 -0400)
don't repeat definition in two places.

src/internal/stdio_impl.h
src/stdio/__lockfile.c
src/stdio/ftrylockfile.c

index 8c81fd53c6585a4946887ed73003bb0f0e5b15b5..ab34da2aead488849178a85705f84b5d876163a3 100644 (file)
@@ -94,6 +94,8 @@ hidden void __register_locked_file(FILE *, struct __pthread *);
 hidden void __unlist_locked_file(FILE *);
 hidden void __do_orphaned_stdio_locks(void);
 
+#define MAYBE_WAITERS 0x40000000
+
 hidden void __getopt_msg(const char *, const char *, const char *, size_t);
 
 #define feof(f) ((f)->flags & F_EOF)
index 0dcb2a426af86b09fa18bf7b1de3be2775999589..0f60a14990943605b12038178c595c7210cc0f73 100644 (file)
@@ -1,8 +1,6 @@
 #include "stdio_impl.h"
 #include "pthread_impl.h"
 
-#define MAYBE_WAITERS 0x40000000
-
 int __lockfile(FILE *f)
 {
        int owner = f->lock, tid = __pthread_self()->tid;
index 3b97807a5e64df7705cce562e834ca2f9c86a07c..50650585be01fc31696ad590e9b6b72d613123a9 100644 (file)
@@ -2,8 +2,6 @@
 #include "pthread_impl.h"
 #include <limits.h>
 
-#define MAYBE_WAITERS 0x40000000
-
 void __do_orphaned_stdio_locks()
 {
        FILE *f;