about summary refs log tree commit diff
path: root/sysdeps/mach/hurd/opendir.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/mach/hurd/opendir.c')
-rw-r--r--sysdeps/mach/hurd/opendir.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sysdeps/mach/hurd/opendir.c b/sysdeps/mach/hurd/opendir.c
index 8ab964a11d..bab84d52f0 100644
--- a/sysdeps/mach/hurd/opendir.c
+++ b/sysdeps/mach/hurd/opendir.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
+/* Copyright (C) 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
 This file is part of the GNU C Library.
 
 The GNU C Library is free software; you can redistribute it and/or
@@ -49,7 +49,7 @@ DEFUN(opendir, (name), CONST char *name)
     {
       __close (fd);
       return NULL;
-    }    
+    }
 
   /* Extract the pointer to the descriptor structure.  */
   __mutex_lock (&_hurd_dtable_lock);
@@ -66,5 +66,7 @@ DEFUN(opendir, (name), CONST char *name)
   dirp->__allocation = 0;
   dirp->__size = 0;
 
+  __libc_lock_init (dirp->__lock);
+
   return dirp;
 }