diff options
author | Vicent Marti <tanoku@gmail.com> | 2011-09-19 03:34:49 +0300 |
---|---|---|
committer | Vicent Marti <tanoku@gmail.com> | 2011-09-19 03:34:49 +0300 |
commit | 87d9869fc30951cec632e0d6a3d1dd47756d2886 (patch) | |
tree | ad39ac1e487e2d5baa64d7fa979122541f6b8bcb /src/util.c | |
parent | bb742ede3d54564ff900fb7246e7b1ff01482b2c (diff) | |
download | libgit2-87d9869fc30951cec632e0d6a3d1dd47756d2886.tar.gz |
Tabify everything
There were quite a few places were spaces were being used instead of
tabs. Try to catch them all. This should hopefully not break anything.
Except for `git blame`. Oh well.
Diffstat (limited to 'src/util.c')
-rw-r--r-- | src/util.c | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/src/util.c b/src/util.c index a178a5a4c..b46a2a15c 100644 --- a/src/util.c +++ b/src/util.c @@ -214,7 +214,7 @@ void git__hexdump(const char *buffer, size_t len) printf("%02X ", (unsigned char)*line & 0xFF); for (j = 0; j < (LINE_WIDTH - last_line); ++j) - printf(" "); + printf(" "); printf("| "); @@ -255,7 +255,7 @@ uint32_t git__hash(const void *key, int len, unsigned int seed) case 3: h ^= data[2] << 16; case 2: h ^= data[1] << 8; case 1: h ^= data[0]; - h *= m; + h *= m; }; h ^= h >> 13; @@ -276,13 +276,13 @@ uint32_t git__hash(const void *key, int len, uint32_t seed) { #define MURMUR_BLOCK() {\ - k1 *= c1; \ - k1 = git__rotl(k1,11);\ - k1 *= c2;\ - h1 ^= k1;\ - h1 = h1*3 + 0x52dce729;\ - c1 = c1*5 + 0x7b7d159c;\ - c2 = c2*5 + 0x6bce6396;\ + k1 *= c1; \ + k1 = git__rotl(k1,11);\ + k1 *= c2;\ + h1 ^= k1;\ + h1 = h1*3 + 0x52dce729;\ + c1 = c1*5 + 0x7b7d159c;\ + c2 = c2*5 + 0x6bce6396;\ } const uint8_t *data = (const uint8_t*)key; @@ -332,20 +332,20 @@ uint32_t git__hash(const void *key, int len, uint32_t seed) */ void **git__bsearch(const void *key, void **base, size_t nmemb, int (*compar)(const void *, const void *)) { - int lim, cmp; - void **p; - - for (lim = nmemb; lim != 0; lim >>= 1) { - p = base + (lim >> 1); - cmp = (*compar)(key, *p); - if (cmp > 0) { /* key > p: move right */ - base = p + 1; - lim--; - } else if (cmp == 0) { - return (void **)p; - } /* else move left */ - } - return NULL; + int lim, cmp; + void **p; + + for (lim = nmemb; lim != 0; lim >>= 1) { + p = base + (lim >> 1); + cmp = (*compar)(key, *p); + if (cmp > 0) { /* key > p: move right */ + base = p + 1; + lim--; + } else if (cmp == 0) { + return (void **)p; + } /* else move left */ + } + return NULL; } /** |