[hackers] [sbase] Fix style for function definitions || sin

From: <git_AT_suckless.org>
Date: Tue, 12 Nov 2013 14:37:45 +0100

commit 80c5ab46ba3651b98bbcb4b8bf74bb9500829608
Author: sin <sin_AT_2f30.org>
Date: Tue Nov 12 13:36:58 2013 +0000

    Fix style for function definitions

diff --git a/util/md5.c b/util/md5.c
index dc2ca8e..b1bf714 100644
--- a/util/md5.c
+++ b/util/md5.c
_AT_@ -24,7 +24,8 @@ static const uint32_t tab[64] = {
         0x6fa87e4f, 0xfe2ce6e0, 0xa3014314, 0x4e0811a1, 0xf7537e82, 0xbd3af235, 0x2ad7d2bb, 0xeb86d391
 };
 
-static void processblock(struct md5 *s, const uint8_t *buf)
+static void
+processblock(struct md5 *s, const uint8_t *buf)
 {
         uint32_t i, W[16], a, b, c, d;
 
_AT_@ -72,7 +73,8 @@ static void processblock(struct md5 *s, const uint8_t *buf)
         s->h[3] += d;
 }
 
-static void pad(struct md5 *s)
+static void
+pad(struct md5 *s)
 {
         unsigned r = s->len % 64;
 
_AT_@ -95,7 +97,8 @@ static void pad(struct md5 *s)
         processblock(s, s->buf);
 }
 
-void md5_init(void *ctx)
+void
+md5_init(void *ctx)
 {
         struct md5 *s = ctx;
         s->len = 0;
_AT_@ -105,7 +108,8 @@ void md5_init(void *ctx)
         s->h[3] = 0x10325476;
 }
 
-void md5_sum(void *ctx, uint8_t md[MD5_DIGEST_LENGTH])
+void
+md5_sum(void *ctx, uint8_t md[MD5_DIGEST_LENGTH])
 {
         struct md5 *s = ctx;
         int i;
_AT_@ -119,7 +123,8 @@ void md5_sum(void *ctx, uint8_t md[MD5_DIGEST_LENGTH])
         }
 }
 
-void md5_update(void *ctx, const void *m, unsigned long len)
+void
+md5_update(void *ctx, const void *m, unsigned long len)
 {
         struct md5 *s = ctx;
         const uint8_t *p = m;
diff --git a/util/sha1.c b/util/sha1.c
index 4003bae..4de2ab6 100644
--- a/util/sha1.c
+++ b/util/sha1.c
_AT_@ -13,7 +13,8 @@ static uint32_t rol(uint32_t n, int k) { return (n << k) | (n >> (32-k)); }
 #define G2(a,b,c,d,e,i) e += rol(a,5)+F2(b,c,d)+W[i]+0x8F1BBCDC; b = rol(b,30)
 #define G3(a,b,c,d,e,i) e += rol(a,5)+F3(b,c,d)+W[i]+0xCA62C1D6; b = rol(b,30)
 
-static void processblock(struct sha1 *s, const uint8_t *buf)
+static void
+processblock(struct sha1 *s, const uint8_t *buf)
 {
         uint32_t W[80], a, b, c, d, e;
         int i;
_AT_@ -66,7 +67,8 @@ static void processblock(struct sha1 *s, const uint8_t *buf)
         s->h[4] += e;
 }
 
-static void pad(struct sha1 *s)
+static void
+pad(struct sha1 *s)
 {
         unsigned r = s->len % 64;
 
_AT_@ -89,7 +91,8 @@ static void pad(struct sha1 *s)
         processblock(s, s->buf);
 }
 
-void sha1_init(void *ctx)
+void
+sha1_init(void *ctx)
 {
         struct sha1 *s = ctx;
 
_AT_@ -101,7 +104,8 @@ void sha1_init(void *ctx)
         s->h[4] = 0xC3D2E1F0;
 }
 
-void sha1_sum(void *ctx, uint8_t md[SHA1_DIGEST_LENGTH])
+void
+sha1_sum(void *ctx, uint8_t md[SHA1_DIGEST_LENGTH])
 {
         struct sha1 *s = ctx;
         int i;
_AT_@ -115,7 +119,8 @@ void sha1_sum(void *ctx, uint8_t md[SHA1_DIGEST_LENGTH])
         }
 }
 
-void sha1_update(void *ctx, const void *m, unsigned long len)
+void
+sha1_update(void *ctx, const void *m, unsigned long len)
 {
         struct sha1 *s = ctx;
         const uint8_t *p = m;
diff --git a/util/sha256.c b/util/sha256.c
index 3284048..eb9f5da 100644
--- a/util/sha256.c
+++ b/util/sha256.c
_AT_@ -25,7 +25,8 @@ static const uint32_t K[64] = {
 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2
 };
 
-static void processblock(struct sha256 *s, const uint8_t *buf)
+static void
+processblock(struct sha256 *s, const uint8_t *buf)
 {
         uint32_t W[64], t1, t2, a, b, c, d, e, f, g, h;
         int i;
_AT_@ -68,7 +69,8 @@ static void processblock(struct sha256 *s, const uint8_t *buf)
         s->h[7] += h;
 }
 
-static void pad(struct sha256 *s)
+static void
+pad(struct sha256 *s)
 {
         unsigned r = s->len % 64;
 
_AT_@ -91,7 +93,8 @@ static void pad(struct sha256 *s)
         processblock(s, s->buf);
 }
 
-void sha256_init(void *ctx)
+void
+sha256_init(void *ctx)
 {
         struct sha256 *s = ctx;
         s->len = 0;
_AT_@ -105,7 +108,8 @@ void sha256_init(void *ctx)
         s->h[7] = 0x5be0cd19;
 }
 
-void sha256_sum(void *ctx, uint8_t md[SHA256_DIGEST_LENGTH])
+void
+sha256_sum(void *ctx, uint8_t md[SHA256_DIGEST_LENGTH])
 {
         struct sha256 *s = ctx;
         int i;
_AT_@ -119,7 +123,8 @@ void sha256_sum(void *ctx, uint8_t md[SHA256_DIGEST_LENGTH])
         }
 }
 
-void sha256_update(void *ctx, const void *m, unsigned long len)
+void
+sha256_update(void *ctx, const void *m, unsigned long len)
 {
         struct sha256 *s = ctx;
         const uint8_t *p = m;
diff --git a/util/sha512.c b/util/sha512.c
index dac3118..394aec7 100644
--- a/util/sha512.c
+++ b/util/sha512.c
_AT_@ -38,7 +38,8 @@ static const uint64_t K[80] = {
 0x4cc5d4becb3e42b6ULL, 0x597f299cfc657e2aULL, 0x5fcb6fab3ad6faecULL, 0x6c44198c4a475817ULL
 };
 
-static void processblock(struct sha512 *s, const uint8_t *buf)
+static void
+processblock(struct sha512 *s, const uint8_t *buf)
 {
         uint64_t W[80], t1, t2, a, b, c, d, e, f, g, h;
         int i;
_AT_@ -85,7 +86,8 @@ static void processblock(struct sha512 *s, const uint8_t *buf)
         s->h[7] += h;
 }
 
-static void pad(struct sha512 *s)
+static void
+pad(struct sha512 *s)
 {
         unsigned r = s->len % 128;
 
_AT_@ -108,7 +110,8 @@ static void pad(struct sha512 *s)
         processblock(s, s->buf);
 }
 
-void sha512_init(void *ctx)
+void
+sha512_init(void *ctx)
 {
         struct sha512 *s = ctx;
         s->len = 0;
_AT_@ -122,7 +125,8 @@ void sha512_init(void *ctx)
         s->h[7] = 0x5be0cd19137e2179ULL;
 }
 
-void sha512_sum(void *ctx, uint8_t md[SHA512_DIGEST_LENGTH])
+void
+sha512_sum(void *ctx, uint8_t md[SHA512_DIGEST_LENGTH])
 {
         struct sha512 *s = ctx;
         int i;
_AT_@ -140,7 +144,8 @@ void sha512_sum(void *ctx, uint8_t md[SHA512_DIGEST_LENGTH])
         }
 }
 
-void sha512_update(void *ctx, const void *m, unsigned long len)
+void
+sha512_update(void *ctx, const void *m, unsigned long len)
 {
         struct sha512 *s = ctx;
         const uint8_t *p = m;
Received on Tue Nov 12 2013 - 14:37:45 CET

This archive was generated by hypermail 2.3.0 : Tue Nov 12 2013 - 14:48:13 CET