Style.
authorangelos <angelos@openbsd.org>
Fri, 3 Mar 2000 11:15:43 +0000 (11:15 +0000)
committerangelos <angelos@openbsd.org>
Fri, 3 Mar 2000 11:15:43 +0000 (11:15 +0000)
sys/kern/uipc_mbuf.c

index 8a2a063..4436f9f 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: uipc_mbuf.c,v 1.21 2000/03/03 06:19:22 angelos Exp $  */
+/*     $OpenBSD: uipc_mbuf.c,v 1.22 2000/03/03 11:15:43 angelos Exp $  */
 /*     $NetBSD: uipc_mbuf.c,v 1.15.4.1 1996/06/13 17:11:44 cgd Exp $   */
 
 /*
@@ -724,36 +724,35 @@ bad:
  * Return a pointer to mbuf/offset of location in mbuf chain.
  */
 struct mbuf *
-m_getptr(struct mbuf *m, int loc, int *off)
+m_getptr(m, loc, off)
+       struct mbuf *m;
+       int loc;
+       int *off;
 {
-    while (loc >= 0)
-    {
-       /* Normal end of search */
-       if (m->m_len > loc)
-       {
-           *off = loc;
-           return m;
-       }
-       else
-       {
-           loc -= m->m_len;
+       while (loc >= 0) {
+               /* Normal end of search */
+               if (m->m_len > loc) {
+                       *off = loc;
+                       return (m);
+               }
+               else {
+                       loc -= m->m_len;
 
-           if (m->m_next == NULL)
-           {
-               if (loc == 0)
-               {
-                   *off = m->m_len; /* Point at the end of valid data */
-                   return m;
+                       if (m->m_next == NULL) {
+                               if (loc == 0) {
+                                       /* Point at the end of valid data */
+                                       *off = m->m_len;
+                                       return (m);
+                               }
+                               else
+                                       return (NULL);
+                       }
+                       else
+                               m = m->m_next;
                }
-               else
-                 return NULL;
-           }
-           else
-             m = m->m_next;
-       }
-    }
+       }
 
-    return NULL;
+       return (NULL);
 }
 
 /*