platform/upstream/curl.git
17 years agoFix overflow detection, thanks to Patrick Monnerat detecting test
Yang Tse [Wed, 17 Oct 2007 18:06:32 +0000 (18:06 +0000)]
Fix overflow detection, thanks to Patrick Monnerat detecting test
failure condition: http://curl.haxx.se/mail/lib-2007-10/0152.html

17 years agosync with lib/setup_once.h
Yang Tse [Wed, 17 Oct 2007 16:59:24 +0000 (16:59 +0000)]
sync with lib/setup_once.h

17 years agoWe use this ZERO_NULL to avoid picky compiler warnings,
Yang Tse [Wed, 17 Oct 2007 16:58:32 +0000 (16:58 +0000)]
We use this ZERO_NULL to avoid picky compiler warnings,
when assigning a NULL pointer to a function pointer var.

17 years agoDefault check for more libraries in CURL_CHECK_LIBS_LDAP,
Yang Tse [Wed, 17 Oct 2007 13:08:10 +0000 (13:08 +0000)]
Default check for more libraries in CURL_CHECK_LIBS_LDAP,
and allow parameter specification of libraries to check.

17 years agoFix compiler warning: signed and unsigned type in conditional expression
Yang Tse [Wed, 17 Oct 2007 00:44:48 +0000 (00:44 +0000)]
Fix compiler warning: signed and unsigned type in conditional expression

17 years agoFix compiler warning: comparison between signed and unsigned
Yang Tse [Wed, 17 Oct 2007 00:10:00 +0000 (00:10 +0000)]
Fix compiler warning: comparison between signed and unsigned

17 years agoANSI C compliant overflow check
Yang Tse [Tue, 16 Oct 2007 23:32:02 +0000 (23:32 +0000)]
ANSI C compliant overflow check

17 years agoFix a bug where fallback from AF_INET6 to AF_INET would not work properly together...
Steinar H. Gunderson [Tue, 16 Oct 2007 21:27:51 +0000 (21:27 +0000)]
Fix a bug where fallback from AF_INET6 to AF_INET would not work properly together with relative search; if you had a search path of .a.com and .b.com, and foo.a.com would return ARES_ENODATA and foo.b.com would return ARES_ENOTFOUND, the lookup would not properly retry with AF_INET as it forgot the first ARES_ENODATA.

17 years agoFixed compiler warning re: unused variable `bigsize'
Dan Fandrich [Tue, 16 Oct 2007 18:09:57 +0000 (18:09 +0000)]
Fixed compiler warning re: unused variable `bigsize'

17 years agoAvoid depending on a header file for the definition of NULL
Yang Tse [Mon, 15 Oct 2007 23:58:11 +0000 (23:58 +0000)]
Avoid depending on a header file for the definition of NULL

17 years agoMention first version with CURLOPT_COPYPOSTFIELDS.
Dan Fandrich [Mon, 15 Oct 2007 21:19:40 +0000 (21:19 +0000)]
Mention first version with CURLOPT_COPYPOSTFIELDS.
Don't confuse NUL with NULL.

17 years agoUpdated minimum libcurl size
Dan Fandrich [Mon, 15 Oct 2007 21:03:40 +0000 (21:03 +0000)]
Updated minimum libcurl size

17 years agoFix dynamic CURLOPT_POSTFIELDS bug: back to static.
Patrick Monnerat [Mon, 15 Oct 2007 18:32:01 +0000 (18:32 +0000)]
Fix dynamic CURLOPT_POSTFIELDS bug: back to static.
CURLOPT_COPYPOSTFIELDS option added for dynamic.
Fix some OS400 features.

17 years agoFix LDAP compile error when LDAP is not available.
Dan Fandrich [Mon, 15 Oct 2007 16:24:46 +0000 (16:24 +0000)]
Fix LDAP compile error when LDAP is not available.
Fixed a typo in the LDAP configure code and made sure NULL is defined
in a test programs that need it.

17 years agoFix custom check for LDAP libraries
Yang Tse [Sun, 14 Oct 2007 23:47:15 +0000 (23:47 +0000)]
Fix custom check for LDAP libraries

17 years agoAdd custom check for LDAP libraries
Yang Tse [Sun, 14 Oct 2007 21:25:10 +0000 (21:25 +0000)]
Add custom check for LDAP libraries

17 years agoAdd custom checks for lber, ldap, ldapssl and ldap_ssl header files
Yang Tse [Sun, 14 Oct 2007 02:37:04 +0000 (02:37 +0000)]
Add custom checks for lber, ldap, ldapssl and ldap_ssl header files

17 years agoChris Leighton:
Daniel Stenberg [Sat, 13 Oct 2007 20:49:51 +0000 (20:49 +0000)]
Chris Leighton:

My understanding is that we use "number" for discrete variables and
"amount" for continuous variables.

So you can say "The amount of flour required depends on..." or, "Last
night I consumed a large amount of beer!".

And, "That tank contains a large number of fish" or, "Over the week I
consumed a number of cases of beer."

I think that features are discrete, so the man page would read "...the
number of features will make your head spin!".

17 years agoAdd check for winldap and winber header files
Yang Tse [Sat, 13 Oct 2007 14:23:15 +0000 (14:23 +0000)]
Add check for winldap and winber header files

17 years agoMade a few more functions static with the protocol handler table in place.
Dan Fandrich [Sat, 13 Oct 2007 00:47:53 +0000 (00:47 +0000)]
Made a few more functions static with the protocol handler table in place.

17 years agoanother Curl_handler fix, the #ifdefs got a bit mixed up...
Daniel Stenberg [Fri, 12 Oct 2007 20:53:43 +0000 (20:53 +0000)]
another Curl_handler fix, the #ifdefs got a bit mixed up...

17 years agoFixed a few compile errors and warnings.
Dan Fandrich [Fri, 12 Oct 2007 18:49:14 +0000 (18:49 +0000)]
Fixed a few compile errors and warnings.

17 years agoadded three serious bugs to fix before release, and marked the previous two
Daniel Stenberg [Fri, 12 Oct 2007 15:26:33 +0000 (15:26 +0000)]
added three serious bugs to fix before release, and marked the previous two
as subject for removal from this list (without any fix)

17 years agoAdded per-protocol callback static tables, replacing callback ptr storage
Patrick Monnerat [Fri, 12 Oct 2007 13:36:37 +0000 (13:36 +0000)]
Added per-protocol callback static tables, replacing callback ptr storage
in the connectdata structure by a single handler table ptr.

17 years agoFixed a couple of typos that messed up the tests.
Dan Fandrich [Fri, 12 Oct 2007 02:09:45 +0000 (02:09 +0000)]
Fixed a couple of typos that messed up the tests.

17 years agoAdded some <keywords> sections and use some key words more consistently.
Dan Fandrich [Fri, 12 Oct 2007 01:44:22 +0000 (01:44 +0000)]
Added some <keywords> sections and use some key words more consistently.

17 years agoFixed the -l option of runtests.pl
Dan Fandrich [Thu, 11 Oct 2007 21:15:09 +0000 (21:15 +0000)]
Fixed the -l option of runtests.pl
Added support for skipping tests based on key words.

17 years agoimprove checking for ldap.h and ldap_ssl.h header files
Yang Tse [Wed, 10 Oct 2007 13:00:11 +0000 (13:00 +0000)]
improve checking for ldap.h and ldap_ssl.h header files

17 years agolber.h needs to be included since ldap.h might not include it
Yang Tse [Tue, 9 Oct 2007 23:51:55 +0000 (23:51 +0000)]
lber.h needs to be included since ldap.h might not include it

17 years agoAdd check for lber.h and ldap.h header files
Yang Tse [Tue, 9 Oct 2007 23:44:14 +0000 (23:44 +0000)]
Add check for lber.h and ldap.h header files

17 years agoadded check for MSVC6 standard PSDK and bail out since insufficient for LDAP support...
Gunter Knauf [Tue, 9 Oct 2007 23:25:58 +0000 (23:25 +0000)]
added check for MSVC6 standard PSDK and bail out since insufficient for LDAP support with current code.

17 years agoalso log error message string
Yang Tse [Tue, 9 Oct 2007 23:24:28 +0000 (23:24 +0000)]
also log error message string

17 years agologmsg already appends '\n'
Yang Tse [Tue, 9 Oct 2007 23:21:29 +0000 (23:21 +0000)]
logmsg already appends '\n'

17 years agofix socklen_t for MSVC6 & 7.
Gunter Knauf [Tue, 9 Oct 2007 22:10:17 +0000 (22:10 +0000)]
fix socklen_t for MSVC6 & 7.

17 years agoadded two more module dependencies for LDAPS.
Gunter Knauf [Tue, 9 Oct 2007 20:15:27 +0000 (20:15 +0000)]
added two more module dependencies for LDAPS.

17 years agoDocumented error codes 77-80, and fixed the one for 60.
Dan Fandrich [Tue, 9 Oct 2007 16:49:41 +0000 (16:49 +0000)]
Documented error codes 77-80, and fixed the one for 60.

17 years agoAdd a paragraph about CURLOPT_CUSTOMREQUEST not actually changing libcurl's
Daniel Stenberg [Tue, 9 Oct 2007 14:53:50 +0000 (14:53 +0000)]
Add a paragraph about CURLOPT_CUSTOMREQUEST not actually changing libcurl's
behavior, it only changes the actual request method keyword and this is not
always what the user/app wants.

17 years agoMichal Marek removed the no longer existing return codes from the curl.1
Daniel Stenberg [Tue, 9 Oct 2007 08:42:50 +0000 (08:42 +0000)]
Michal Marek removed the no longer existing return codes from the curl.1
man page.

17 years agoAdded needed 'HAVE_*' defines.
Gisle Vanem [Mon, 8 Oct 2007 14:39:52 +0000 (14:39 +0000)]
Added needed 'HAVE_*' defines.

17 years ago'FD_CLOXEC' is meaningless on MSDOS/Watt-32.
Gisle Vanem [Mon, 8 Oct 2007 14:38:51 +0000 (14:38 +0000)]
'FD_CLOXEC' is meaningless on MSDOS/Watt-32.

17 years agoKnown bug #47, which confused libcurl if doing NTLM auth over a proxy with
Daniel Stenberg [Sun, 7 Oct 2007 08:28:03 +0000 (08:28 +0000)]
Known bug #47, which confused libcurl if doing NTLM auth over a proxy with
a response that was larger than 16KB is now improved slightly so that now
the restriction at 16KB is for the headers only and it should be a rare
situation where the response-headers exceed 16KB. Thus, I consider #47 fixed
and the header limitation is now known as known bug #48.

17 years ago<ws2tcpip.h> needed for 'socklen_t' typedef.
Gisle Vanem [Sat, 6 Oct 2007 17:20:06 +0000 (17:20 +0000)]
<ws2tcpip.h> needed for 'socklen_t' typedef.

17 years agoadd url to the wikipedia article for a longer description
Daniel Stenberg [Fri, 5 Oct 2007 15:18:34 +0000 (15:18 +0000)]
add url to the wikipedia article for a longer description

17 years agoAlexey Pesternikov documented CURLOPT_OPENSOCKETDATA and
Daniel Stenberg [Fri, 5 Oct 2007 15:16:18 +0000 (15:16 +0000)]
Alexey Pesternikov documented CURLOPT_OPENSOCKETDATA and
CURLOPT_OPENSOCKETFUNCTION

17 years agoMichael Wallner made the CULROPT_COOKIELIST option support a new magic
Daniel Stenberg [Fri, 5 Oct 2007 14:37:33 +0000 (14:37 +0000)]
Michael Wallner made the CULROPT_COOKIELIST option support a new magic
string: "FLUSH". Using that will cause libcurl to flush its cookies to the
CURLOPT_COOKIEJAR file.

17 years agoThe new file docs/libcurl/ABI describes how we view ABI breakages, soname
Daniel Stenberg [Thu, 4 Oct 2007 22:05:25 +0000 (22:05 +0000)]
The new file docs/libcurl/ABI describes how we view ABI breakages, soname
bumps and what the version number's significance to all that is.

17 years agoI enabled test 1009 and made the --local-port use a wide range to reduce the
Daniel Stenberg [Thu, 4 Oct 2007 21:26:26 +0000 (21:26 +0000)]
I enabled test 1009 and made the --local-port use a wide range to reduce the
risk of failures.

17 years agoKim Rinnewitz reported that --local-port didn't work with TFTP transfers.
Daniel Stenberg [Thu, 4 Oct 2007 10:01:41 +0000 (10:01 +0000)]
Kim Rinnewitz reported that --local-port didn't work with TFTP transfers.
This happened because the tftp code always uncondionally did a bind()
without caring if one already had been done and then it failed. I wrote a
test case (1009) to verify this, but it is a bit error-prone since it will
have to pick a fixed local port number and since the tests are run on so
many different hosts in different situations I add it in disabled state.

17 years agoRemoved a piece of redundant code (process_answer already takes care of it).
Steinar H. Gunderson [Thu, 4 Oct 2007 08:12:12 +0000 (08:12 +0000)]
Removed a piece of redundant code (process_answer already takes care of it).

17 years agoAnother timeout fix in ares_getnameinfo().
Steinar H. Gunderson [Thu, 4 Oct 2007 08:09:52 +0000 (08:09 +0000)]
Another timeout fix in ares_getnameinfo().

17 years agoSend the timeout count in ares_getnameinfo().
Steinar H. Gunderson [Thu, 4 Oct 2007 08:09:04 +0000 (08:09 +0000)]
Send the timeout count in ares_getnameinfo().

17 years agoMoved the NULL check for channel upwards in ares_destroy().
Steinar H. Gunderson [Thu, 4 Oct 2007 08:07:47 +0000 (08:07 +0000)]
Moved the NULL check for channel upwards in ares_destroy().

17 years agoClarified the comment over ares_cancel.
Steinar H. Gunderson [Thu, 4 Oct 2007 08:06:25 +0000 (08:06 +0000)]
Clarified the comment over ares_cancel.

17 years agoOn error, close "log/server.response"
Yang Tse [Thu, 4 Oct 2007 02:09:33 +0000 (02:09 +0000)]
On error, close "log/server.response"

17 years agoIf TCP_NODELAY is not defined we can't disable the Nagle algorithm
Yang Tse [Wed, 3 Oct 2007 23:38:07 +0000 (23:38 +0000)]
If TCP_NODELAY is not defined we can't disable the Nagle algorithm

17 years agoCleanup no longer used macros
Yang Tse [Wed, 3 Oct 2007 16:58:10 +0000 (16:58 +0000)]
Cleanup no longer used macros

17 years agoFix compiler warning: local variable may be used without having been initialized
Yang Tse [Wed, 3 Oct 2007 16:26:56 +0000 (16:26 +0000)]
Fix compiler warning: local variable may be used without having been initialized

17 years agoUpgrade OS400 wrappers and RPG copy file according to latest code updates
Patrick Monnerat [Wed, 3 Oct 2007 15:09:21 +0000 (15:09 +0000)]
Upgrade OS400 wrappers and RPG copy file according to latest code updates

17 years agoFix issue related with the use of ares_timeout() result.
Yang Tse [Wed, 3 Oct 2007 13:19:34 +0000 (13:19 +0000)]
Fix issue related with the use of ares_timeout() result.

17 years agoexported symbols must use lowercase "curl_", and I also fixed two compiler
Daniel Stenberg [Wed, 3 Oct 2007 08:58:40 +0000 (08:58 +0000)]
exported symbols must use lowercase "curl_", and I also fixed two compiler
warnings, one C99 thing and the bad pointer sent to the callback

17 years agorecount contributors after the 7.17.0 release
Daniel Stenberg [Wed, 3 Oct 2007 08:54:35 +0000 (08:54 +0000)]
recount contributors after the 7.17.0 release

17 years agopeople from the 7.17.0 announcement
Daniel Stenberg [Wed, 3 Oct 2007 08:51:36 +0000 (08:51 +0000)]
people from the 7.17.0 announcement

17 years ago"97 - check ip callback", check
Daniel Stenberg [Wed, 3 Oct 2007 08:46:45 +0000 (08:46 +0000)]
"97 - check ip callback", check

17 years agoAlexey Pesternikov introduced CURLOPT_OPENSOCKETFUNCTION and
Daniel Stenberg [Wed, 3 Oct 2007 08:45:00 +0000 (08:45 +0000)]
Alexey Pesternikov introduced CURLOPT_OPENSOCKETFUNCTION and
CURLOPT_OPENSOCKETDATA to set a callback that allows an application to replace
the socket() call used by libcurl. It basically allows the app to change
address, protocol or whatever of the socket. (I also did some whitespace
indent/cleanups in lib/url.c which kind of hides some of these changes, sorry
for mixing those in.)

17 years agoI renamed the CURLE_SSL_PEER_CERTIFICATE error code to
Daniel Stenberg [Wed, 3 Oct 2007 08:07:50 +0000 (08:07 +0000)]
I renamed the CURLE_SSL_PEER_CERTIFICATE error code to
CURLE_PEER_FAILED_VERIFICATION (standard CURL_NO_OLDIES style), and made this
return code get used by the previous SSH MD5 fingerprint check in case it
fails.

17 years agoBased on a patch brought by Johnny Luong, libcurl now offers
Daniel Stenberg [Wed, 3 Oct 2007 08:00:42 +0000 (08:00 +0000)]
Based on a patch brought by Johnny Luong, libcurl now offers
CURLOPT_SSH_HOST_PUBLIC_KEY_MD5 and the curl tool --hostpubmd5. They both make
the SCP or SFTP connection verify the remote host's md5 checksum of the public
key before doing a connect, to reduce the risk of a man-in-the-middle attack.

17 years ago"99 - curl_easy_close()" seems to have gone uninteresting
Daniel Stenberg [Tue, 2 Oct 2007 22:00:03 +0000 (22:00 +0000)]
"99 - curl_easy_close()" seems to have gone uninteresting

17 years ago102, check
Daniel Stenberg [Tue, 2 Oct 2007 21:59:06 +0000 (21:59 +0000)]
102, check

17 years agoFix memory leak under low memory conditions.
Yang Tse [Tue, 2 Oct 2007 19:19:47 +0000 (19:19 +0000)]
Fix memory leak under low memory conditions.

17 years agoAvoid a segfault when generating a DNS "Transaction ID" in internal
Yang Tse [Tue, 2 Oct 2007 18:26:48 +0000 (18:26 +0000)]
Avoid a segfault when generating a DNS "Transaction ID" in internal
function init_id_key() under low memory conditions.

17 years agoRenamed a couple of global variables to avoid shadowing warnings
Yang Tse [Tue, 2 Oct 2007 16:05:28 +0000 (16:05 +0000)]
Renamed a couple of global variables to avoid shadowing warnings

17 years agoFix compiler warning
Yang Tse [Tue, 2 Oct 2007 15:26:30 +0000 (15:26 +0000)]
Fix compiler warning

17 years ago<winber.h> needed for Windows LDAP client 32 API support
Yang Tse [Tue, 2 Oct 2007 14:48:38 +0000 (14:48 +0000)]
<winber.h> needed for Windows LDAP client 32 API support

17 years agoLinking with wldap32.lib needed for Windows LDAP client 32 API support
Yang Tse [Tue, 2 Oct 2007 14:26:04 +0000 (14:26 +0000)]
Linking with wldap32.lib needed for Windows LDAP client 32 API support

17 years agoAdd ares_llist.c and ares_llist.h to MSCV project file.
Yang Tse [Tue, 2 Oct 2007 11:13:58 +0000 (11:13 +0000)]
Add ares_llist.c and ares_llist.h to MSCV project file.

17 years agoknown bug #46: chunked-encoded CONNECT responses from a http proxy now works.
Daniel Stenberg [Tue, 2 Oct 2007 10:21:36 +0000 (10:21 +0000)]
known bug #46: chunked-encoded CONNECT responses from a http proxy now works.
Added test case 1008 to verify. Note that #47 is still there.

17 years agoDisable the Nagle algorithm and send back responses in small chunks in an
Daniel Stenberg [Tue, 2 Oct 2007 10:13:37 +0000 (10:13 +0000)]
Disable the Nagle algorithm and send back responses in small chunks in an
attempt to force smaller bits to get read by clients.

17 years agodocument --post301, based on the phrasing in curl_easy_setopt.3 for
Daniel Stenberg [Tue, 2 Oct 2007 09:57:48 +0000 (09:57 +0000)]
document --post301, based on the phrasing in curl_easy_setopt.3 for
CURLOPT_POST301 written by Philip Langdale

17 years agoCURLOPT_POST301 section, added by Philip Langdale
Daniel Stenberg [Tue, 2 Oct 2007 09:56:52 +0000 (09:56 +0000)]
CURLOPT_POST301 section, added by Philip Langdale

17 years agoFixed the problem where next_lookup would use 'status' uninitialized. Now
Daniel Stenberg [Tue, 2 Oct 2007 08:12:30 +0000 (08:12 +0000)]
Fixed the problem where next_lookup would use 'status' uninitialized. Now
it gets passed the initial value as an argument.

17 years agoAvoid inline C99ism, and move c-ares routines for managing doubly-linked lists.
Yang Tse [Tue, 2 Oct 2007 02:18:01 +0000 (02:18 +0000)]
Avoid inline C99ism, and move c-ares routines for managing doubly-linked lists.

17 years agoares_strerror() segfaulted if the input error number was out of the currently
Daniel Stenberg [Mon, 1 Oct 2007 22:52:31 +0000 (22:52 +0000)]
ares_strerror() segfaulted if the input error number was out of the currently
supported range.

17 years agoPrevent ares_strerror() from segfaulting if an invalid error code is passed
Daniel Stenberg [Mon, 1 Oct 2007 22:51:38 +0000 (22:51 +0000)]
Prevent ares_strerror() from segfaulting if an invalid error code is passed
in as argument!

17 years agoAdded test536 that was accidentally missing. I also wrote up a new makefile
Daniel Stenberg [Sun, 30 Sep 2007 22:58:24 +0000 (22:58 +0000)]
Added test536 that was accidentally missing. I also wrote up a new makefile
target called 'filecheck' so that if you run 'make filecheck' in this directory
it'll check if the local files are also mentioned in the Makefile.am so that
they are properly included in release archives!

17 years agoAlex Fishman reported a curl_easy_escape() problem that was made the
Daniel Stenberg [Sun, 30 Sep 2007 22:40:24 +0000 (22:40 +0000)]
Alex Fishman reported a curl_easy_escape() problem that was made the
function do wrong on all input bytes that are >= 0x80 (decimal 128) due to a
signed / unsigned mistake in the code. I fixed it and added test case 543 to
verify.

17 years agoFix compiler warning
Yang Tse [Sun, 30 Sep 2007 19:43:23 +0000 (19:43 +0000)]
Fix compiler warning

17 years agocheck availability of <netinet/tcp.h>
Yang Tse [Sun, 30 Sep 2007 02:12:11 +0000 (02:12 +0000)]
check availability of <netinet/tcp.h>

17 years agoFix missing right parenthesis
Yang Tse [Sun, 30 Sep 2007 01:27:39 +0000 (01:27 +0000)]
Fix missing right parenthesis

17 years agoFix comparison between signed and unsigned
Yang Tse [Sun, 30 Sep 2007 01:01:43 +0000 (01:01 +0000)]
Fix comparison between signed and unsigned

17 years agoimprove portability, defining MAXDNAME and MAXCDNAME
Yang Tse [Sun, 30 Sep 2007 00:37:47 +0000 (00:37 +0000)]
improve portability, defining MAXDNAME and MAXCDNAME

17 years agoFix a memory leak that I recently inadvertedly introduced.
Steinar H. Gunderson [Sun, 30 Sep 2007 00:08:01 +0000 (00:08 +0000)]
Fix a memory leak that I recently inadvertedly introduced.

17 years agoUse ISDIGIT instead of isdigit; fixes a gcc warning.
Steinar H. Gunderson [Sat, 29 Sep 2007 21:57:05 +0000 (21:57 +0000)]
Use ISDIGIT instead of isdigit; fixes a gcc warning.

17 years agoImmanuel Gregoire fixed a problem with persistent transfers over SFTP - the
Daniel Stenberg [Sat, 29 Sep 2007 21:34:34 +0000 (21:34 +0000)]
Immanuel Gregoire fixed a problem with persistent transfers over SFTP - the
previous proto struct was kept.

17 years agoPort the TCP socket fix made in ares_fds() to ares_getsock() as well.
Steinar H. Gunderson [Sat, 29 Sep 2007 19:26:59 +0000 (19:26 +0000)]
Port the TCP socket fix made in ares_fds() to ares_getsock() as well.

17 years agoPreviously, processing a large batch of timeouts was O(n^2) in the number of
Steinar H. Gunderson [Sat, 29 Sep 2007 18:18:47 +0000 (18:18 +0000)]
Previously, processing a large batch of timeouts was O(n^2) in the number of
outstanding queries, and processing a DNS response packet was O(n) in the
number of outstanding queries. To speed things up in Google, we added a few circular,
doubly-linked lists of queries that are hash-bucketed based on
the attributes we care about, so most important operations are now O(1).

It might be that the number of buckets are higher than most people would need,
but on a quick calculation it should only be 100kB or so even on a 64-bit
system, so I've let it stay as-is.

17 years agoWe should standarise on C comments.
Gisle Vanem [Sat, 29 Sep 2007 14:37:47 +0000 (14:37 +0000)]
We should standarise on C comments.

17 years agoFix compiler warning in setsockopt().
Gisle Vanem [Sat, 29 Sep 2007 14:34:59 +0000 (14:34 +0000)]
Fix compiler warning in setsockopt().

17 years agoTCP queries can time out too, not just UDP queries. (Patch from the Google tree.)
Steinar H. Gunderson [Sat, 29 Sep 2007 14:25:14 +0000 (14:25 +0000)]
TCP queries can time out too, not just UDP queries. (Patch from the Google tree.)

17 years agoRead and process as many packets as possible in read_udp_packets, to avoid having...
Steinar H. Gunderson [Sat, 29 Sep 2007 14:21:47 +0000 (14:21 +0000)]
Read and process as many packets as possible in read_udp_packets, to avoid having to run the entire event loop once per packet. (Patch from the Google tree.)

17 years agoThere are two different places in write_tcp_data() that advance the send_queue; howev...
Steinar H. Gunderson [Sat, 29 Sep 2007 14:09:14 +0000 (14:09 +0000)]
There are two different places in write_tcp_data() that advance the send_queue; however, they are slightly different and only the first one properly uses a while loop. Consolidate both into a single function that DTTR. (Patch from the Google tree.)