* whitespace reformatting. Remove remaining '%W%' SCCS IDs.
authorErez Zadok <ezk@cs.sunysb.edu>
Wed, 3 Aug 2005 00:01:34 +0000 (00:01 +0000)
committerErez Zadok <ezk@cs.sunysb.edu>
Wed, 3 Aug 2005 00:01:34 +0000 (00:01 +0000)
ChangeLog
amd/info_exec.c
amd/info_hesiod.c
conf/mount/mount_aix.c
conf/mount/mount_aix3.c
conf/mount/mount_linux.c
conf/mtab/mtab_linux.c
libamu/wire.c

index 1b25b6de1511b75bbc8b9e94c53b33f4954af48a..0fad5d893874254b7ef42aadf08c547e7e37ce2b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 2005-08-02  Erez Zadok  <ezk@cs.sunysb.edu>
 
+       * whitespace reformatting.  Remove remaining '%W%' SCCS IDs.
+
        * amd/mntfs.c (free_mntfs): don't discard the last reference to an
        mntfs that had been mounted already.  It won't have the
        MFF_RESTARTED flag on, as it gets turned off after the entry is
index 0cc6dff4f7fef2b271dd1e4d0bd3d4750f56049d..e726c52db3042b7dd618241bb10c232d4c4a9769 100644 (file)
@@ -36,9 +36,8 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- *      %W% (Berkeley) %G%
  *
- * $Id: info_exec.c,v 1.2 2005/03/08 07:47:10 ezk Exp $
+ * $Id: info_exec.c,v 1.3 2005/08/03 00:01:34 ezk Exp $
  *
  */
 
@@ -276,47 +275,47 @@ exec_map_open(char *emap, char *key)
     return -1;
   }
 
-  switch((p1 = vfork())) {
+  switch ((p1 = vfork())) {
+  case -1:
+    /* parent: fork error */
+    close(nullfd);
+    close(pdes[0]);
+    close(pdes[1]);
+    return -1;
+  case 0:
+    /* child #1 */
+    switch ((p2 = vfork())) {
     case -1:
-      /* parent: fork error */
-      close(nullfd);
-      close(pdes[0]);
-      close(pdes[1]);
-      return -1;
+      /* child #1: fork error */
+      exit(errno);
     case 0:
-      /* child #1 */
-      switch((p2 = vfork())) {
-        case -1:
-          /* child #1: fork error */
-          exit(errno);
-        case 0:
-          /* child #2: init will reap our status */
-          if (pdes[1] != STDOUT_FILENO) {
-            dup2(pdes[1], STDOUT_FILENO);
-            close(pdes[1]);
-          }
-
-          if (nullfd != STDERR_FILENO) {
-            dup2(nullfd, STDERR_FILENO);
-            close(nullfd);
-          }
-
-          for (i=0; i<FD_SETSIZE; i++)
-            if (i != STDOUT_FILENO  &&  i != STDERR_FILENO)
-              close(i);
-
-          /* make the write descriptor non-blocking */
-          if (!set_nonblock(STDOUT_FILENO)) {
-            close(STDOUT_FILENO);
-            exit(-1);
-          }
-
-          execve(emap, argv, NULL);
-          exit(errno);         /* in case execve failed */
+      /* child #2: init will reap our status */
+      if (pdes[1] != STDOUT_FILENO) {
+       dup2(pdes[1], STDOUT_FILENO);
+       close(pdes[1]);
+      }
+
+      if (nullfd != STDERR_FILENO) {
+       dup2(nullfd, STDERR_FILENO);
+       close(nullfd);
       }
 
-      /* child #1 */
-      exit(0);
+      for (i=0; i<FD_SETSIZE; i++)
+       if (i != STDOUT_FILENO  &&  i != STDERR_FILENO)
+         close(i);
+
+      /* make the write descriptor non-blocking */
+      if (!set_nonblock(STDOUT_FILENO)) {
+       close(STDOUT_FILENO);
+       exit(-1);
+      }
+
+      execve(emap, argv, NULL);
+      exit(errno);             /* in case execve failed */
+    }
+
+    /* child #1 */
+    exit(0);
   }
 
   /* parent */
@@ -324,7 +323,7 @@ exec_map_open(char *emap, char *key)
   close(pdes[1]);
 
   /* anti-zombie insurance */
-  while(waitpid(p1,0,0) < 0)
+  while (waitpid(p1,0,0) < 0)
     if (errno != EINTR)
       exit(errno);
 
index acb03efb3629f8d5acc6ac0d44bc24933771860a..fb4b640c835b415674fad36365af138652270ec1 100644 (file)
@@ -37,7 +37,7 @@
  * SUCH DAMAGE.
  *
  *
- * $Id: info_hesiod.c,v 1.16 2005/01/03 20:56:45 ezk Exp $
+ * $Id: info_hesiod.c,v 1.17 2005/08/03 00:01:34 ezk Exp $
  *
  */
 
@@ -78,7 +78,7 @@ amu_hesiod_init(mnt_map *m, char *map, time_t *tp)
   *tp = 0;
 
 #ifdef HAVE_HESIOD_INIT
-  if(!hesiod_context && hesiod_init(&hesiod_context) != 0)
+  if (!hesiod_context && hesiod_init(&hesiod_context) != 0)
     return ENOENT;
 #endif /* HAVE_HESIOD_INIT */
 
index 961f48a604aca895faaed78a14f5eaf88f1e6c1a..a2263bae87b19702366b2f0dde3a532dbaa183c9 100644 (file)
@@ -36,9 +36,8 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- *      %W% (Berkeley) %G%
  *
- * $Id: mount_aix.c,v 1.16 2005/07/06 22:34:26 ezk Exp $
+ * $Id: mount_aix.c,v 1.17 2005/08/03 00:01:35 ezk Exp $
  *
  */
 
index 153077b35c4c60cb0026f7207dd1c1dca05f4edb..d63159018f465a4145df44501bdf1e5298e3b68a 100644 (file)
@@ -36,9 +36,8 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- *      %W% (Berkeley) %G%
  *
- * $Id: mount_aix3.c,v 1.1 2005/07/06 22:34:26 ezk Exp $
+ * $Id: mount_aix3.c,v 1.2 2005/08/03 00:01:35 ezk Exp $
  *
  */
 
index cf8572332499e1d16c68770537c813e20f591582..df2b3d77012e8a8a97e942f64cb2867b5329d9a0 100644 (file)
@@ -37,7 +37,7 @@
  * SUCH DAMAGE.
  *
  *
- * $Id: mount_linux.c,v 1.44 2005/07/29 10:47:19 ezk Exp $
+ * $Id: mount_linux.c,v 1.45 2005/08/03 00:01:35 ezk Exp $
  */
 
 /*
@@ -752,7 +752,7 @@ find_unused_loop_device(void)
        somedev++;
        fd = open(dev, O_RDONLY);
        if (fd >= 0) {
-         if(ioctl(fd, LOOP_GET_STATUS, &loopinfo) == 0)
+         if (ioctl(fd, LOOP_GET_STATUS, &loopinfo) == 0)
            someloop++;         /* in use */
          else if (errno == ENXIO) {
            close(fd);
@@ -781,7 +781,7 @@ find_unused_loop_device(void)
 
   if (!somedev) {
     dlog("Could not find any device /dev/loop#");
-  } else if(!someloop) {
+  } else if (!someloop) {
     if (loop_known == 1) {
       dlog("Could not find any loop device.");
       dlog("...Maybe /dev/loop# has a wrong major number?");
index cceb4d85fc0ab998bad8bc62f0b868422f43948e..81675e27f3690c3b11df3fcaeb6f08a2acf86dda 100644 (file)
@@ -36,9 +36,8 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- *      %W% (Berkeley) %G%
  *
- * $Id: mtab_linux.c,v 1.3 2005/08/02 01:28:57 ezk Exp $
+ * $Id: mtab_linux.c,v 1.4 2005/08/03 00:01:35 ezk Exp $
  *
  */
 
index 415a1fa1e466c13aa76d0860c2edf68023a4a2ee..2d0655378ab624b3b0c9d658530cf699bc7b8c83 100644 (file)
@@ -37,7 +37,7 @@
  * SUCH DAMAGE.
  *
  *
- * $Id: wire.c,v 1.24 2005/06/23 20:48:42 ezk Exp $
+ * $Id: wire.c,v 1.25 2005/08/03 00:01:35 ezk Exp $
  *
  */
 
@@ -203,7 +203,7 @@ getwire_lookup(u_long address, u_long netmask, int ishost)
      */
     if (!np) {
       u_long short_subnet = subnet;
-      while(short_subnet && (short_subnet & 0x000000ff) == 0)
+      while (short_subnet && (short_subnet & 0x000000ff) == 0)
        short_subnet >>= 8;
       np = getnetbyaddr(short_subnet, AF_INET);
       if (np)