From 8cf883eb29acb3eb09842830c65a414c647b6a7c Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Thu, 1 Sep 2011 19:44:00 +0200 Subject: [PATCH] http.c: remove new-line from error() calls one new-line is always appended to the message by the error function. --- http.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/http.c b/http.c index 747616e..865917f 100644 --- a/http.c +++ b/http.c @@ -99,7 +99,7 @@ static size_t write_cb(void *src, size_t smemb, size_t nmemb, void *data) { dest->block = realloc(dest->block, dest->len + size); if (dest->block == NULL) { - error("out of memory\n"); + error("out of memory"); return 0; } memcpy(dest->block + dest->len, src, size); @@ -138,7 +138,7 @@ struct http_data* http_fetch_page(const char *url) { res = curl_easy_perform(handle); if (res != CURLE_OK) { - error("curl: (%s) %s\n", url, curl_easy_strerror(res)); + error("curl: (%s) %s", url, curl_easy_strerror(res)); goto error; } @@ -178,7 +178,7 @@ int http_download_file(const char *url, const char *dir) { res = curl_easy_perform(handle); if (res != CURLE_OK) { - error("curl: (%s) %s\n", url, curl_easy_strerror(res)); + error("curl: (%s) %s", url, curl_easy_strerror(res)); goto error; }