diff options
author | Vincent Sanders <vince@kyllikki.org> | 2014-07-02 17:07:05 +0100 |
---|---|---|
committer | Vincent Sanders <vince@kyllikki.org> | 2014-07-02 17:07:29 +0100 |
commit | a71865b328b721dcba49696f942335ec2baddc0f (patch) | |
tree | c8c6ed8609c7a6c0f06d5285aea12e44cb4f1154 | |
parent | 4073a991ddb92adb3eb0d91d3cbc11f97807c0cb (diff) | |
download | netsurf-a71865b328b721dcba49696f942335ec2baddc0f.tar.gz netsurf-a71865b328b721dcba49696f942335ec2baddc0f.tar.bz2 |
turn off verbose fetch debugging
-rw-r--r-- | content/fetch.c | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/content/fetch.c b/content/fetch.c index 6ee3872aa..2160204ef 100644 --- a/content/fetch.c +++ b/content/fetch.c @@ -61,17 +61,27 @@ /* Define this to turn on verbose fetch logging */ #undef DEBUG_FETCH_VERBOSE -#define DEBUG_FETCH_VERBOSE - -/** The maximum number of fetchers that can be added */ -#define MAX_FETCHERS 8 +/** Verbose fetcher logging */ #ifdef DEBUG_FETCH_VERBOSE #define FETCH_LOG(x) LOG(x) #else #define FETCH_LOG(x) #endif +/** The maximum number of fetchers that can be added */ +#define MAX_FETCHERS 8 + +/** The time in ms between polling the fetchers. + * + * \todo The schedule timeout should be profiled to see if there is a + * better value or even if it needs to be dynamic. + */ +#define SCHEDULE_TIME 10 + +/** The fdset timeout in ms */ +#define FDSET_TIMEOUT 1000 + /** * Information about a fetcher for a given scheme. */ @@ -265,7 +275,7 @@ static void fetcher_poll(void *unused) } /* schedule active fetchers to run again in 10ms */ - guit->browser->schedule(10, fetcher_poll, NULL); + guit->browser->schedule(SCHEDULE_TIME, fetcher_poll, NULL); } } @@ -395,7 +405,7 @@ nserror fetcher_fdset(fd_set *read_fd_set, * select on. All the other fetchers continue to need * polling frequently. */ - guit->browser->schedule(1000, fetcher_poll, NULL); + guit->browser->schedule(FDSET_TIMEOUT, fetcher_poll, NULL); } *maxfd_out = maxfd; |