From b99fe7e4662d91c8727271f19e83ad42f406e1e1 Mon Sep 17 00:00:00 2001 From: Ashish Gupta Date: Sun, 23 Apr 2017 18:58:16 +0200 Subject: Get logging working. --- content/fetch.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'content/fetch.c') diff --git a/content/fetch.c b/content/fetch.c index 598ac8dd7..872cf0ff0 100644 --- a/content/fetch.c +++ b/content/fetch.c @@ -70,7 +70,7 @@ /** Verbose fetcher logging */ #ifdef DEBUG_FETCH_VERBOSE -#define FETCH_LOG(x...) debug_board_printf(x); debug_board_printf("\n"); +#define FETCH_LOG(x...) LOG(x) #else #define FETCH_LOG(x...) #endif @@ -307,12 +307,14 @@ nserror fetcher_init(void) return ret; } #endif + #ifdef _TARGET_IS_KOLIBRIOS ret = fetch_httplib_kolibri_register(); if (ret != NSERROR_OK) { return ret; } #endif + ret = fetch_data_register(); if (ret != NSERROR_OK) { return ret; @@ -603,6 +605,7 @@ fetch_start(nsurl *url, /* exported interface documented in content/fetch.h */ void fetch_abort(struct fetch *f) { + debug_board_printf("---- fetch.c : fetch_abort for fetch 0x%x\n", f); assert(f); NSLOG(fetch, DEBUG, "fetch %p, fetcher %p, url '%s'", f, f->fetcher_handle, @@ -789,6 +792,7 @@ void fetch_remove_from_queues(struct fetch *fetch) void fetch_set_http_code(struct fetch *fetch, long http_code) { NSLOG(fetch, DEBUG, "Setting HTTP code to %ld", http_code); + FETCH_LOG("Setting HTTP code to %ld for fetch 0x%x", http_code, fetch); fetch->http_code = http_code; } -- cgit v1.2.3