diff options
author | Nick White <hg@njw.me.uk> | 2011-07-15 23:40:58 +0100 |
---|---|---|
committer | Nick White <hg@njw.me.uk> | 2011-07-15 23:40:58 +0100 |
commit | 9bdbf7b6158887256df70d5f006c46607f192c83 (patch) | |
tree | 6c4aea3a4868c7c9948d28fd271f4a6bd0083d56 | |
parent | e85bc3e20bb05cd43bfdf6c55d113906e969db15 (diff) |
Little cleanups
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | getgbook.c | 7 | ||||
-rw-r--r-- | util.c | 1 |
3 files changed, 4 insertions, 6 deletions
@@ -5,7 +5,7 @@ all: getgbook .c.o: @echo CC $< - @$(CC) -c -g $(CFLAGS) $< + @$(CC) -c -g -Wall $(CFLAGS) $< $(OBJ): util.c @@ -45,9 +45,8 @@ char *getgbookid(char *isbn) int main(int argc, char *argv[]) { - int i, s; - char *bookid, url[80], isbn[16]; - char *curpage; + int i; + char *bookid, isbn[16]; FILE *srv; if(argc != 2) @@ -58,9 +57,7 @@ int main(int argc, char *argv[]) i = dial(hostname, "80"); srv = fdopen(i, "r+"); - /* get google book id */ bookid = getgbookid(isbn); - printf("bookid is %s\n", bookid); free(bookid); @@ -1,5 +1,6 @@ /* See COPYING file for copyright, license and warranty details. */ +#include <unistd.h> #include <netdb.h> #include <netinet/in.h> #include <sys/socket.h> |