History log of /curl/lib/hostip.c (Results 126 – 150 of 396)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: curl-7_49_1, curl-7_49_0
# 4f45240b 29-Apr-2016 Daniel Stenberg

lib: include curl_printf.h as one of the last headers

curl_printf.h defines printf to curl_mprintf, etc. This can cause
problems with external headers which may use
__attribute__((fo

lib: include curl_printf.h as one of the last headers

curl_printf.h defines printf to curl_mprintf, etc. This can cause
problems with external headers which may use
__attribute__((format(printf, ...))) markers etc.

To avoid that they cause problems with system includes, we include
curl_printf.h after any system headers. That makes the three last
headers to always be, and we keep them in this order:

curl_printf.h
curl_memory.h
memdebug.h

None of them include system headers, they all do funny #defines.

Reported-by: David Benjamin

Fixes #743

show more ...


# a71012c0 03-Apr-2016 Daniel Stenberg

code: style updates


# 2505fbbd 29-Mar-2016 Daniel Stenberg

hostip.c: minor white space edit for style


Revision tags: curl-7_48_0, curl-7_47_1
# 4af40b36 02-Feb-2016 Daniel Stenberg

URLs: change all http:// URLs to https://


Revision tags: curl-7_47_0, curl-7_46_0, curl-7_45_0, curl-7_44_0, curl-7_43_0
# 4883f701 02-May-2015 Anthony Avina

hostip: fix unintended destruction of hash table

.. and added unit1602 for hash.c


# b419e7ae 12-May-2015 Daniel Stenberg

hostcache: made all host caches use structs, not pointers

This avoids unnecessary dynamic allocs and as this also removed the last
users of *hash_alloc() and *hash_destroy(), those two f

hostcache: made all host caches use structs, not pointers

This avoids unnecessary dynamic allocs and as this also removed the last
users of *hash_alloc() and *hash_destroy(), those two functions are now
removed.

show more ...


Revision tags: curl-7_42_1, curl-7_42_0
# 81ee1e69 03-Apr-2015 Daniel Stenberg

hostip: fix compiler warnings

introduced in the previous mini-series of 3 commits


# 846f4920 17-Mar-2015 Stefan Bühler

actually implement CURLOPT_RESOLVE removals

- also log when a CURLOPT_RESOLVE entry couldn't get parsed


# b4be97fb 17-Mar-2015 Stefan Bühler

move Curl_share_lock and ref counting into Curl_fetch_addr


# 0db83197 17-Mar-2015 Stefan Bühler

fix refreshing of obsolete dns cache entries

- cache entries must be also refreshed when they are in use
- have the cache count as inuse reference too, freeing timestamp == 0 special

fix refreshing of obsolete dns cache entries

- cache entries must be also refreshed when they are in use
- have the cache count as inuse reference too, freeing timestamp == 0 special
value
- use timestamp == 0 for CURLOPT_RESOLVE entries which don't get refreshed
- remove CURLOPT_RESOLVE special inuse reference (timestamp == 0 will prevent refresh)
- fix Curl_hostcache_clean - CURLOPT_RESOLVE entries don't have a special
reference anymore, and it would also release non CURLOPT_RESOLVE references
- fix locking in Curl_hostcache_clean
- fix unit1305.c: hash now keeps a reference, need to set inuse = 1

show more ...


# 93959995 17-Mar-2015 Daniel Stenberg

checksrc: use space after comma


# 851c2926 14-Mar-2015 Tobias Stoeckmann

hostip: Fix signal race in Curl_resolv_timeout.

A signal handler for SIGALRM is installed in Curl_resolv_timeout. It is
configured to interrupt system calls and uses siglongjmp to return

hostip: Fix signal race in Curl_resolv_timeout.

A signal handler for SIGALRM is installed in Curl_resolv_timeout. It is
configured to interrupt system calls and uses siglongjmp to return into
the function if alarm() goes off.

The signal handler is installed before curl_jmpenv is initialized.
This means that an already installed alarm timer could trigger the
newly installed signal handler, leading to undefined behavior when it
accesses the uninitialized curl_jmpenv.

Even if there is no previously installed alarm available, the code in
Curl_resolv_timeout itself installs an alarm before the environment is
fully set up. If the process is sent into suspend right after that, the
signal handler could be called too early as in previous scenario.

To fix this, the signal handler should only be installed and the alarm
timer only be set after sigsetjmp has been called.

show more ...


# df5578a7 03-Mar-2015 Daniel Stenberg

mprintf.h: remove #ifdef CURLDEBUG

... and as a consequence, introduce curl_printf.h with that re-define
magic instead and make all libcurl code use that instead.


Revision tags: curl-7_41_0, curl-7_40_0
# 95479549 06-Jan-2015 Daniel Stenberg

hostip: remove 'stale' argument from Curl_fetch_addr proto

Also, remove the log output of the resolved name is NOT in the cache in
the spirit of only telling when something is actually h

hostip: remove 'stale' argument from Curl_fetch_addr proto

Also, remove the log output of the resolved name is NOT in the cache in
the spirit of only telling when something is actually happening.

show more ...


# 151ae594 27-Dec-2014 Steve Holme

code/docs: Use correct case for IPv4 and IPv6

For consistency, as we seem to have a bit of a mixed bag, changed all
instances of ipv4 and ipv6 in comments and documentations to use the

code/docs: Use correct case for IPv4 and IPv6

For consistency, as we seem to have a bit of a mixed bag, changed all
instances of ipv4 and ipv6 in comments and documentations to use the
correct case.

show more ...


Revision tags: curl-7_39_0, curl-7_38_0
# 09b5a998 20-Aug-2014 Michael Wallner

resolve: cache lookup for async resolvers

While waiting for a host resolve, check if the host cache may have
gotten the name already (by someone else), for when the same name is
reso

resolve: cache lookup for async resolvers

While waiting for a host resolve, check if the host cache may have
gotten the name already (by someone else), for when the same name is
resolved by several simultanoues requests.

The resolver thread occasionally gets stuck in getaddrinfo() when the
DNS or anything else is crappy or slow, so when a host is found in the
DNS cache, leave the thread alone and let itself cleanup the mess.

show more ...


Revision tags: curl-7_37_1, curl-7_37_0, curl-7_36_0, curl-7_35_0
# 31860ab8 28-Jan-2014 Romulo A. Ceccon

hostip: don't remove DNS entries that are in use

hostcache_timestamp_remove() should remove old *unused* entries from the
host cache, but it never checked whether the entry was actually

hostip: don't remove DNS entries that are in use

hostcache_timestamp_remove() should remove old *unused* entries from the
host cache, but it never checked whether the entry was actually in
use. This complements commit 030a2b8cb.

Bug: http://curl.haxx.se/bug/view.cgi?id=1327

show more ...


Revision tags: curl-7_34_0
# 030a2b8c 24-Nov-2013 Daniel Stenberg

hostip: don't prune DNS cache entries that are in use

When adding entries to the DNS cache with CURLOPT_RESOLVE, they are
marked 'inuse' forever to prevent them from ever being removed i

hostip: don't prune DNS cache entries that are in use

When adding entries to the DNS cache with CURLOPT_RESOLVE, they are
marked 'inuse' forever to prevent them from ever being removed in normal
operations. Still, the code that pruned out-of-date DNS entries didn't
care for the 'inuse' struct field and pruned it anyway!

Reported-by: Romulo A. Ceccon
Bug: http://curl.haxx.se/bug/view.cgi?id=1303

show more ...


Revision tags: curl-7_33_0, curl-7_32_0
# d20def20 08-Aug-2013 Daniel Stenberg

global dns cache: fix memory leak

The take down of the global dns cache didn't take CURLOPT_RESOLVE names
into account.


# d2b36e46 08-Aug-2013 Daniel Stenberg

global dns cache: didn't work [regression]

CURLOPT_DNS_USE_GLOBAL_CACHE broke in commit c43127414d89ccb (been
broken since the libcurl 7.29.0 release). While this option has been
doc

global dns cache: didn't work [regression]

CURLOPT_DNS_USE_GLOBAL_CACHE broke in commit c43127414d89ccb (been
broken since the libcurl 7.29.0 release). While this option has been
documented as deprecated for almost a decade and nobody even reported
this bug, it should remain functional.

Added test case 1512 to verify

show more ...


Revision tags: curl-7_31_0, curl-7_30_0, curl-7_29_0
# 5a053ffe 06-Jan-2013 Yang Tse

build: fix circular header inclusion with other packages

This commit renames lib/setup.h to lib/curl_setup.h and
renames lib/setup_once.h to lib/curl_setup_once.h.

Removes the n

build: fix circular header inclusion with other packages

This commit renames lib/setup.h to lib/curl_setup.h and
renames lib/setup_once.h to lib/curl_setup_once.h.

Removes the need and usage of a header inclusion guard foreign
to libcurl. [1]

Removes the need and presence of an alarming notice we carried
in old setup_once.h [2]

----------------------------------------

1 - lib/setup_once.h used __SETUP_ONCE_H macro as header inclusion guard
up to commit ec691ca3 which changed this to HEADER_CURL_SETUP_ONCE_H,
this single inclusion guard is enough to ensure that inclusion of
lib/setup_once.h done from lib/setup.h is only done once.

Additionally lib/setup.h has always used __SETUP_ONCE_H macro to
protect inclusion of setup_once.h even after commit ec691ca3, this
was to avoid a circular header inclusion triggered when building a
c-ares enabled version with c-ares sources available which also has
a setup_once.h header. Commit ec691ca3 exposes the real nature of
__SETUP_ONCE_H usage in lib/setup.h, it is a header inclusion guard
foreign to libcurl belonging to c-ares's setup_once.h

The renaming this commit does, fixes the circular header inclusion,
and as such removes the need and usage of a header inclusion guard
foreign to libcurl. Macro __SETUP_ONCE_H no longer used in libcurl.

2 - Due to the circular interdependency of old lib/setup_once.h and the
c-ares setup_once.h header, old file lib/setup_once.h has carried
back from 2006 up to now days an alarming and prominent notice about
the need of keeping libcurl's and c-ares's setup_once.h in sync.

Given that this commit fixes the circular interdependency, the need
and presence of mentioned notice is removed.

All mentioned interdependencies come back from now old days when
the c-ares project lived inside a curl subdirectory. This commit
removes last traces of such fact.

show more ...


# 4a5aa668 04-Jan-2013 Yang Tse

Revert changes relative to lib/*.[ch] recent renaming

This reverts renaming and usage of lib/*.h header files done
28-12-2012, reverting 2 commits:

f871de0... build: make use

Revert changes relative to lib/*.[ch] recent renaming

This reverts renaming and usage of lib/*.h header files done
28-12-2012, reverting 2 commits:

f871de0... build: make use of 76 lib/*.h renamed files
ffd8e12... build: rename 76 lib/*.h files

This also reverts removal of redundant include guard (redundant thanks
to changes in above commits) done 2-12-2013, reverting 1 commit:

c087374... curl_setup.h: remove redundant include guard

This also reverts renaming and usage of lib/*.c source files done
3-12-2013, reverting 3 commits:

13606bb... build: make use of 93 lib/*.c renamed files
5b6e792... build: rename 93 lib/*.c files
7d83dff... build: commit 13606bbfde follow-up 1

Start of related discussion thread:

http://curl.haxx.se/mail/lib-2013-01/0012.html

Asking for confirmation on pushing this revertion commit:

http://curl.haxx.se/mail/lib-2013-01/0048.html

Confirmation summary:

http://curl.haxx.se/mail/lib-2013-01/0079.html

NOTICE: The list of 2 files that have been modified by other
intermixed commits, while renamed, and also by at least one
of the 6 commits this one reverts follows below. These 2 files
will exhibit a hole in history unless git's '--follow' option
is used when viewing logs.

lib/curl_imap.h
lib/curl_smtp.h

show more ...


# 13606bbf 03-Jan-2013 Yang Tse

build: make use of 93 lib/*.c renamed files

93 *.c source files renamed to use our standard naming scheme.

This change affects 77 files in libcurl's source tree.


# f871de00 28-Dec-2012 Yang Tse

build: make use of 76 lib/*.h renamed files

76 private header files renamed to use our standard naming scheme.

This change affects 322 files in libcurl's source tree.


# a0b20716 14-Dec-2012 Yang Tse

setup_once.h: refactor inclusion of <unistd.h> and <sys/socket.h>

Inclusion of top two most included header files now done in setup_once.h


12345678910>>...16