about summary refs log tree commit diff
path: root/libio/libioP.h
diff options
context:
space:
mode:
authorRoland McGrath <roland@hack.frob.com>2012-08-17 09:35:36 -0700
committerRoland McGrath <roland@hack.frob.com>2012-08-17 09:35:36 -0700
commitb2e1c562728699642e98c528bed175929cceff4d (patch)
treecf4d64dc3600a1da1f4d32697ddf494c7d81d0d0 /libio/libioP.h
parentc75ccd4c3a84993ea392f23f2cf75f7274e22cc1 (diff)
downloadglibc-b2e1c562728699642e98c528bed175929cceff4d.tar.gz
glibc-b2e1c562728699642e98c528bed175929cceff4d.tar.xz
glibc-b2e1c562728699642e98c528bed175929cceff4d.zip
Make libio compile without _IO_MTSAFE_IO.
Diffstat (limited to 'libio/libioP.h')
-rw-r--r--libio/libioP.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/libio/libioP.h b/libio/libioP.h
index 486c670b51..aa2b3bfa90 100644
--- a/libio/libioP.h
+++ b/libio/libioP.h
@@ -933,3 +933,17 @@ _IO_acquire_lock_clear_flags2_fct (_IO_FILE **p)
   if ((fp->_flags & _IO_USER_LOCK) == 0)
     _IO_funlockfile (fp);
 }
+
+#if !defined _IO_MTSAFE_IO && !defined NOT_IN_libc
+# define _IO_acquire_lock(_fp)						      \
+  do {									      \
+    _IO_FILE *_IO_acquire_lock_file = NULL
+# define _IO_acquire_lock_clear_flags2(_fp)				      \
+  do {									      \
+    _IO_FILE *_IO_acquire_lock_file = (_fp)
+# define _IO_release_lock(_fp)						      \
+    if (_IO_acquire_lock_file != NULL)					      \
+      _IO_acquire_lock_file->_flags2 &= ~(_IO_FLAGS2_FORTIFY		      \
+                                          | _IO_FLAGS2_SCANF_STD);	      \
+  } while (0)
+#endif