]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Indent (merged from SQUID2)
authorhno <>
Sat, 19 Oct 2002 04:42:00 +0000 (04:42 +0000)
committerhno <>
Sat, 19 Oct 2002 04:42:00 +0000 (04:42 +0000)
lib/MemPool.c
lib/radix.c
lib/rfc1035.c
lib/rfc2617.c
lib/splay.c
lib/util.c

index daa6bf2254f91e86b71343441d3fdde834e25650..a8f4ebcdcb2eb0620f84810071609d7bc19c0a66 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: MemPool.c,v 1.12 2002/08/09 10:57:42 robertc Exp $
+ * $Id: MemPool.c,v 1.13 2002/10/18 22:42:00 hno Exp $
  *
  * DEBUG: section 63    Low Level Memory Pool Management
  * AUTHOR: Alex Rousskov, Andres Kroonmaa
@@ -200,7 +200,7 @@ memCompObjChunks(void *obj, MemChunk * chunk)
 {
     if (obj < chunk->objCache)
        return -1;
-    if (obj < (void *)((char *)chunk->objCache + lastPool->chunk_size))
+    if (obj < (void *) ((char *) chunk->objCache + lastPool->chunk_size))
        return 0;
     return 1;
 }
@@ -217,7 +217,7 @@ memPoolChunkNew(MemPool * pool)
     Free = chunk->freeList = chunk->objCache;
 
     for (i = 1; i < pool->chunk_capacity; i++) {
-       *Free = (void *) ((char *)Free + pool->obj_size);
+       *Free = (void *) ((char *) Free + pool->obj_size);
        Free = *Free;
     }
     chunk->nextFreeChunk = pool->nextFreeChunk;
@@ -255,7 +255,7 @@ memPoolPush(MemPool * pool, void *obj)
      * not really need to be cleared.. There was a condition based on
      * the object size here, but such condition is not safe.
      */
-       memset(obj, 0, pool->obj_size);
+    memset(obj, 0, pool->obj_size);
     Free = obj;
     *Free = pool->freeCache;
     pool->freeCache = obj;
index 955d7529335038347ef54c32c0fa84beed22a09e..110240a147f048333cc1477425378dfbb22b289a 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * $Id: radix.c,v 1.17 2002/04/19 22:23:01 hno Exp $
+ * $Id: radix.c,v 1.18 2002/10/18 22:42:00 hno Exp $
  *
  * DEBUG: section 53     Radix tree data structure implementation
  * AUTHOR: NetBSD Derived
@@ -128,7 +128,7 @@ static char *rn_zeros, *rn_ones;
 #define rn_l rn_u.rn_node.rn_L
 #define rn_r rn_u.rn_node.rn_R
 #define rm_mask rm_rmu.rmu_mask
-#define rm_leaf rm_rmu.rmu_leaf /* extra field would make 32 bytes */
+#define rm_leaf rm_rmu.rmu_leaf        /* extra field would make 32 bytes */
 
 
 /* Helper macros */
@@ -259,7 +259,7 @@ squid_rn_lookup(void *v_arg, void *m_arg, struct squid_radix_node_head *head)
 }
 
 static int
-rn_satsifies_leaf (char *trial, register struct squid_radix_node *leaf, int skip)
+rn_satsifies_leaf(char *trial, register struct squid_radix_node *leaf, int skip)
 {
     register char *cp = trial, *cp2 = leaf->rn_key, *cp3 = leaf->rn_mask;
     char *cplim;
@@ -914,7 +914,7 @@ squid_rn_delete(void *v_arg, void *netmask_arg, struct squid_radix_node_head *he
 }
 
 int
-squid_rn_walktree(struct squid_radix_node_head *h, int (*f)(struct squid_radix_node *, void *), void *w)
+squid_rn_walktree(struct squid_radix_node_head *h, int (*f) (struct squid_radix_node *, void *), void *w)
 {
     int error;
     struct squid_radix_node *base, *next;
index 9aa6574d058bbf6aca3266c976ad98217fddcb2e..41800562a88626305287a96dcd50cf5fd187c0be 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: rfc1035.c,v 1.27 2002/09/15 06:40:54 robertc Exp $
+ * $Id: rfc1035.c,v 1.28 2002/10/18 22:42:00 hno Exp $
  *
  * Low level DNS protocol routines
  * AUTHOR: Duane Wessels
@@ -312,7 +312,7 @@ rfc1035NameUnpack(const char *buf, size_t sz, off_t * off, char *name, size_t ns
            /* blasted compression */
            unsigned short s;
            off_t ptr;
-           if (rdepth > 64)            /* infinite pointer loop */
+           if (rdepth > 64)    /* infinite pointer loop */
                return 1;
            memcpy(&s, buf + (*off), sizeof(s));
            s = ntohs(s);
index 15081b2cbc417d0bb972e1224b5584c02e154202..5ae2730c0d73fed27b791bddfd6173871f44f623 100644 (file)
@@ -13,7 +13,7 @@
 
 
 /*
- * $Id: rfc2617.c,v 1.5 2001/10/17 13:30:50 hno Exp $
+ * $Id: rfc2617.c,v 1.6 2002/10/18 22:42:00 hno Exp $
  *
  * DEBUG:
  * AUTHOR: RFC 2617 & Robert Collins
@@ -111,7 +111,7 @@ DigestCalcHA1(
        MD5Update(&Md5Ctx, pszRealm, strlen(pszRealm));
        MD5Update(&Md5Ctx, ":", 1);
        MD5Update(&Md5Ctx, pszPassword, strlen(pszPassword));
-       MD5Final((unsigned char *)HA1, &Md5Ctx);
+       MD5Final((unsigned char *) HA1, &Md5Ctx);
     }
     if (strcasecmp(pszAlg, "md5-sess") == 0) {
        MD5Init(&Md5Ctx);
@@ -120,7 +120,7 @@ DigestCalcHA1(
        MD5Update(&Md5Ctx, pszNonce, strlen(pszNonce));
        MD5Update(&Md5Ctx, ":", 1);
        MD5Update(&Md5Ctx, pszCNonce, strlen(pszCNonce));
-       MD5Final((unsigned char *)HA1, &Md5Ctx);
+       MD5Final((unsigned char *) HA1, &Md5Ctx);
     }
     CvtHex(HA1, SessionKey);
 }
@@ -154,7 +154,7 @@ DigestCalcResponse(
        MD5Update(&Md5Ctx, ":", 1);
        MD5Update(&Md5Ctx, HEntity, HASHHEXLEN);
     }
-    MD5Final((unsigned char *)HA2, &Md5Ctx);
+    MD5Final((unsigned char *) HA2, &Md5Ctx);
     CvtHex(HA2, HA2Hex);
 
     /* calculate response
@@ -173,6 +173,6 @@ DigestCalcResponse(
        MD5Update(&Md5Ctx, ":", 1);
     }
     MD5Update(&Md5Ctx, HA2Hex, HASHHEXLEN);
-    MD5Final((unsigned char *)RespHash, &Md5Ctx);
+    MD5Final((unsigned char *) RespHash, &Md5Ctx);
     CvtHex(RespHash, Response);
 }
index fd4a1abcfb28c9444190bed9fc76306b579a1474..0d8e778e7c60817b73f7706aedc4dd7a47d4c4c2 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * $Id: splay.c,v 1.13 2002/04/06 08:49:26 adrian Exp $
+ * $Id: splay.c,v 1.14 2002/10/18 22:42:00 hno Exp $
  *
  * based on ftp://ftp.cs.cmu.edu/user/sleator/splaying/top-down-splay.c
  * http://bobo.link.cs.cmu.edu/cgi-bin/splay/splay-cgi.pl
@@ -107,9 +107,9 @@ splay_delete(const void *data, splayNode * top, SPLAYCMP * compare)
 {
     splayNode *x;
     if (top == NULL)
-        return NULL;
+       return NULL;
     top = splay_splay(data, top, compare);
-    if (splayLastResult == 0) {                /* found it */
+    if (splayLastResult == 0) {        /* found it */
        if (top->left == NULL) {
            x = top->right;
        } else {
@@ -119,7 +119,7 @@ splay_delete(const void *data, splayNode * top, SPLAYCMP * compare)
        xfree(top);
        return x;
     }
-    return top;                                /* It wasn't there */
+    return top;                        /* It wasn't there */
 }
 
 void
index 86d043605b7320773ade8bcadc3f6fe521c0a71a..06fc0a46d3ea38755be6ac8960a26ebd4a085ed3 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: util.c,v 1.87 2002/10/02 11:06:30 robertc Exp $
+ * $Id: util.c,v 1.88 2002/10/18 22:42:00 hno Exp $
  *
  * DEBUG: 
  * AUTHOR: Harvest Derived
@@ -490,7 +490,7 @@ xfree(void *s)
 void
 xxfree(const void *s_const)
 {
-    void *s = (void *)s_const;
+    void *s = (void *) s_const;
     PROF_start(xxfree);
 #if XMALLOC_TRACE
     xmalloc_show_trace(s, -1);
@@ -651,11 +651,11 @@ xstrerror(void)
     static char strerror_buf[BUFSIZ];
 
     snprintf(strerror_buf, BUFSIZ, "%s", strerror(errno));
-   
-    if (strerror_buf) 
+
+    if (strerror_buf)
        snprintf(xstrerror_buf, BUFSIZ, "(%d) %s", errno, strerror_buf);
     else
-        snprintf(xstrerror_buf, BUFSIZ, "(%d) Unknown", errno); 
+       snprintf(xstrerror_buf, BUFSIZ, "(%d) Unknown", errno);
     return xstrerror_buf;
 }
 
@@ -787,11 +787,11 @@ double_to_str(char *buf, int buf_size, double value)
 {
     /* select format */
     if (value < 1e9)
-        snprintf(buf, buf_size, "%.2f MB", value / 1e6);
+       snprintf(buf, buf_size, "%.2f MB", value / 1e6);
     else if (value < 1e12)
-        snprintf(buf, buf_size, "%.3f GB", value / 1e9);
+       snprintf(buf, buf_size, "%.3f GB", value / 1e9);
     else
-        snprintf(buf, buf_size, "%.4f TB", value / 1e12);
+       snprintf(buf, buf_size, "%.4f TB", value / 1e12);
     return buf;
 }