From 94ec3569e3c42693045ee33c36152526cdf46f78 Mon Sep 17 00:00:00 2001 From: Nick White Date: Tue, 10 Jul 2012 22:52:33 +0100 Subject: Clean up style --- getabook.c | 3 ++- getgbook.c | 3 ++- util.c | 3 +-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/getabook.c b/getabook.c index 524fd20..0ad6944 100644 --- a/getabook.c +++ b/getabook.c @@ -64,7 +64,8 @@ int fillurls(char *buf) { int getpagelist() { - char url[URLMAX], b[STRMAX] = ""; + char url[URLMAX]; + char b[STRMAX] = ""; char *buf = NULL; char *s, *c; int i; diff --git a/getgbook.c b/getgbook.c index 77893f6..2042a75 100644 --- a/getgbook.c +++ b/getgbook.c @@ -77,7 +77,8 @@ int getpagelist() int getpageurls(char *pagecode, char *cookie) { char url[URLMAX], code[STRMAX], m[STRMAX]; - char *c = NULL, *d, *p, *q, *buf = NULL; + char *c = NULL, *buf = NULL; + char *d, *p, *q; int i, j; snprintf(url, URLMAX, "/books?id=%s&pg=%s&jscmd=click3&q=subject:a&redir_esc=y", bookid, pagecode); diff --git a/util.c b/util.c index c25181e..54a0a64 100644 --- a/util.c +++ b/util.c @@ -57,8 +57,7 @@ int request(char *host, char *request, char *savecookie, char **body) { char *headpos; size_t headsize; char headline[BUFSIZ] = ""; - char *buf; - char *cur, *pos; + char *buf, *cur, *pos; if((fd = dial(host, "80")) == -1) return 0; -- cgit v1.2.3