about summary refs log tree commit diff
path: root/libio/iofputs.c
diff options
context:
space:
mode:
Diffstat (limited to 'libio/iofputs.c')
-rw-r--r--libio/iofputs.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/libio/iofputs.c b/libio/iofputs.c
index 088fd5fd4f..b596a99213 100644
--- a/libio/iofputs.c
+++ b/libio/iofputs.c
@@ -37,13 +37,11 @@ _IO_fputs (str, fp)
   _IO_size_t len = strlen (str);
   int result = EOF;
   CHECK_FILE (fp, EOF);
-  _IO_cleanup_region_start ((void (*) __P ((void *))) _IO_funlockfile, fp);
-  _IO_flockfile (fp);
+  _IO_acquire_lock (fp);
   if ((_IO_vtable_offset (fp) != 0 || _IO_fwide (fp, -1) == -1)
       && _IO_sputn (fp, str, len) == len)
     result = 1;
-  _IO_funlockfile (fp);
-  _IO_cleanup_region_end (0);
+  _IO_release_lock (fp);
   return result;
 }
 libc_hidden_def (_IO_fputs)