*** empty log message ***
[gnulib.git] / lib / rmdir.c
index 58b2edb..805b3ca 100644 (file)
@@ -1,5 +1,5 @@
 /* BSD compatible remove directory function for System V
-   Copyright (C) 1988, 1990 Free Software Foundation, Inc.
+   Copyright (C) 1988, 1990, 2000 Free Software Foundation, Inc.
 
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -44,7 +44,8 @@ int
 rmdir (dpath)
      char *dpath;
 {
-  int cpid, status;
+  pid_t cpid;
+  int status;
   struct stat statbuf;
 
   if (stat (dpath, &statbuf) != 0)
@@ -73,7 +74,7 @@ rmdir (dpath)
       while (wait (&status) != cpid)
        /* Do nothing.  */ ;
 
-      if (status & 0xFFFF)
+      if (status)
        {
 
          /* /bin/rmdir failed.  */