From 56d06fcfce528f73f0a6310e21bc5fdce0dfa5a7 Mon Sep 17 00:00:00 2001 From: Nick White Date: Mon, 12 Sep 2011 23:12:44 +0100 Subject: Have shared pointers be pointed to rather than copied --- getgbook.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'getgbook.c') diff --git a/getgbook.c b/getgbook.c index f43abec..ff10e82 100644 --- a/getgbook.c +++ b/getgbook.c @@ -19,7 +19,7 @@ typedef struct { int num; char url[URLMAX]; char name[STRMAX]; - char cookie[COOKIEMAX]; + char *cookie; } Page; Page **pages; @@ -102,7 +102,7 @@ int getpageurls(char *pagecode, char *cookie) { *p = *d; } strncpy(p, "&q=subject:a", 13); - strncpy(pages[j]->cookie, cookie, COOKIEMAX); + pages[j]->cookie = cookie; break; } } -- cgit v1.2.3