curl/lib
Daniel Stenberg c6aedf680f fread_func: move callback pointer from set to state struct
... and assign it from the set.fread_func_set pointer in the
Curl_init_CONNECT function. This A) avoids that we have code that
assigns fields in the 'set' struct (which we always knew was bad) and
more importantly B) it makes it impossibly to accidentally leave the
wrong value for when the handle is re-used etc.

Introducing a state-init functionality in multi.c, so that we can set a
specific function to get called when we enter a state. The
Curl_init_CONNECT is thus called when switching to the CONNECT state.

Bug: https://github.com/bagder/curl/issues/346

Closes #346
2015-10-15 23:32:19 +02:00
..
vtls openssl: Fix set up of pkcs12 certificate verification chain 2015-10-11 23:14:04 +02:00
.gitignore gitignore: ignore more generated VC Makefiles 2015-09-03 23:35:41 +02:00
amigaos.c
amigaos.h
arpa_telnet.h
asyn-ares.c
asyn-thread.c
asyn.h
base64.c
checksrc.pl checksrc: detect fopen() for text without the FOPEN_* macros 2015-06-02 08:28:10 +02:00
checksrc.whitelist checksrc: detect fopen() for text without the FOPEN_* macros 2015-06-02 08:28:10 +02:00
CMakeLists.txt
config-amigaos.h
config-dos.h
config-mac.h
config-os400.h
config-riscos.h
config-symbian.h
config-tpf.h
config-vxworks.h
config-win32.h win32: make recent Borland compilers use long long 2015-09-30 00:03:35 +02:00
config-win32ce.h
conncache.c conncache: fixed memory leak on OOM (torture tests) 2015-05-24 11:19:07 +02:00
conncache.h bundles: store no/default/pipeline/multiplex 2015-05-18 09:33:36 +02:00
connect.c http2: set TCP_NODELAY unconditionally 2015-09-27 23:23:58 +02:00
connect.h http2: set TCP_NODELAY unconditionally 2015-09-27 23:23:58 +02:00
content_encoding.c
content_encoding.h
cookie.c cookie: Fix bug in export if any-domain cookie is present 2015-06-18 19:37:20 -04:00
cookie.h
curl_addrinfo.c
curl_addrinfo.h
curl_base64.h
curl_config.h.cmake cmake: added Windows SSL support 2015-08-25 22:42:28 +02:00
curl_des.c des: Fixed compilation warning from commit 613e5022fe 2015-08-30 21:45:30 +01:00
curl_des.h des: Fix header conditional for Curl_des_set_odd_parity 2015-10-08 02:07:12 -04:00
curl_endian.c
curl_endian.h
curl_fnmatch.c
curl_fnmatch.h
curl_gethostname.c
curl_gethostname.h
curl_gssapi.c curl_gssapi: remove 'const' to fix compiler warnings 2015-08-02 00:24:38 +02:00
curl_gssapi.h
curl_hmac.h
curl_ldap.h
curl_md4.h
curl_md5.h
curl_memory.h
curl_memrchr.c
curl_memrchr.h
curl_multibyte.c
curl_multibyte.h
curl_ntlm_core.c ntlm: error out without 64bit support as the code needs it 2015-10-09 23:51:54 +02:00
curl_ntlm_core.h
curl_ntlm_msgs.c
curl_ntlm_msgs.h
curl_ntlm_wb.c ntlm_wb: Fix theoretical memory leak 2015-07-16 14:22:45 -04:00
curl_ntlm_wb.h
curl_ntlm.c ntlm: mark deliberate switch case fall-through 2015-08-24 11:29:22 +02:00
curl_ntlm.h
curl_printf.h
curl_rtmp.c
curl_rtmp.h
curl_sasl_gssapi.c sasl: Updated SPN variables and comments for consistency 2015-08-31 12:43:58 +01:00
curl_sasl_sspi.c sasl: Updated SPN variables and comments for consistency 2015-08-31 12:43:58 +01:00
curl_sasl.c sasl: Updated SPN variables and comments for consistency 2015-08-31 12:43:58 +01:00
curl_sasl.h sasl: Only define Curl_sasl_digest_get_pair() when CRYPTO_AUTH enabled 2015-08-31 12:44:01 +01:00
curl_sec.h
curl_setup_once.h
curl_setup.h curl_sspi: fix possibly undefined CRYPT_E_REVOKED 2015-09-10 02:17:33 -04:00
curl_sspi.c sspi: Fix typo from left over from old code which referenced NTLM 2015-08-01 23:09:03 +01:00
curl_sspi.h curl_sspi: fix possibly undefined CRYPT_E_REVOKED 2015-09-10 02:17:33 -04:00
curl_threads.c
curl_threads.h
curlx.h
dict.c
dict.h
dotdot.c
dotdot.h
easy.c curl_global_init: set the memory function pointers correct 2015-10-09 16:13:54 +02:00
easyif.h
escape.c
escape.h
file.c read_callback: move to SessionHandle from connectdata 2015-05-20 23:06:45 +02:00
file.h
fileinfo.c
fileinfo.h
firefox-db2pem.sh firefox-db2pem: fix wildcard to find Firefox default profile 2015-04-13 15:31:26 +02:00
formdata.c build: fix failures with -Wcast-align and -Werror 2015-09-26 23:10:20 +02:00
formdata.h
ftp.c fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
ftp.h
ftplistparser.c
ftplistparser.h
getenv.c
getinfo.c getinfo: Fix return code for unknown CURLINFO options 2015-10-04 17:29:43 -04:00
getinfo.h
gopher.c gopher: don't send NUL byte 2015-10-01 18:15:11 +02:00
gopher.h
hash.c hostip: fix unintended destruction of hash table 2015-05-18 11:15:43 +02:00
hash.h hostip: fix unintended destruction of hash table 2015-05-18 11:15:43 +02:00
hmac.c
hostasyn.c
hostcheck.c
hostcheck.h
hostip4.c
hostip6.c
hostip.c hostip: fix unintended destruction of hash table 2015-05-18 11:15:43 +02:00
hostip.h hostcache: made all host caches use structs, not pointers 2015-05-12 09:46:53 +02:00
hostsyn.c
http2.c http2: Fix http2_recv to return -1 if recv returned -1 2015-10-09 00:29:25 -04:00
http2.h http2: setup the new pushed stream properly 2015-06-24 23:44:42 +02:00
http_chunks.c HTTP: ignore "Content-Encoding: compress" 2015-07-25 00:46:01 +02:00
http_chunks.h
http_digest.c
http_digest.h
http_negotiate_sspi.c http_negotiate_sspi: added missing data variable 2015-04-30 12:13:49 +02:00
http_negotiate.c Negotiate: custom service names for SPNEGO. 2015-04-28 08:29:56 +02:00
http_negotiate.h
http_proxy.c FTP: do the HTTP CONNECT for data connection blocking 2015-06-17 14:00:12 +02:00
http_proxy.h FTP: fixed compiling with --disable-proxy, broken in b88f980a 2015-06-18 23:20:10 +02:00
http.c fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
http.h http2: discard frames with no SessionHandle 2015-08-11 08:16:33 +02:00
idn_win32.c
if2ip.c build: fix failures with -Wcast-align and -Werror 2015-09-26 23:10:20 +02:00
if2ip.h
imap.c
imap.h
inet_ntop.c
inet_ntop.h
inet_pton.c inet_pton.c: Fix MSVC run-time check failure (2) 2015-09-03 11:37:50 +02:00
inet_pton.h
krb5.c
ldap.c
libcurl.def
libcurl.plist
libcurl.rc
libcurl.vers.in
llist.c
llist.h
Makefile.am libcurl: VERSIONINFO update 2015-07-21 14:01:19 +02:00
makefile.amiga
Makefile.b32 makefiles: Added our standard copyright header 2015-08-30 14:51:13 +01:00
makefile.dj makefiles: Added our standard copyright header 2015-08-30 14:51:13 +01:00
Makefile.inc bundles: merged into conncache.c 2015-05-12 23:21:33 +02:00
Makefile.m32 makefiles: Added our standard copyright header 2015-08-30 14:51:13 +01:00
Makefile.netware makefiles: Added our standard copyright header 2015-08-30 14:51:13 +01:00
Makefile.vc6 build: removed bundles.c from make files 2015-05-14 14:55:48 +02:00
Makefile.vxworks
Makefile.Watcom makefiles: Added our standard copyright header 2015-08-30 14:51:13 +01:00
md4.c
md5.c
memdebug.c curl_setup: Add macros for FOPEN_READTEXT, FOPEN_WRITETEXT 2015-06-01 03:21:23 -04:00
memdebug.h
mk-ca-bundle.pl
mk-ca-bundle.vbs
mprintf.c
multi.c fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
multihandle.h http2: initial implementation of the push callback 2015-06-24 23:44:42 +02:00
multiif.h http2: setup the new pushed stream properly 2015-06-24 23:44:42 +02:00
netrc.c curl_setup: Add macros for FOPEN_READTEXT, FOPEN_WRITETEXT 2015-06-01 03:21:23 -04:00
netrc.h
non-ascii.c
non-ascii.h
nonblock.c
nonblock.h
nwlib.c
nwos.c
objnames-test08.sh
objnames-test10.sh
objnames.inc
openldap.c openldap: only part of LDAP query results received 2015-09-19 23:06:03 +02:00
parsedate.c
parsedate.h
pingpong.c
pingpong.h
pipeline.c pipeline: switch some code over to functions 2015-05-18 09:33:47 +02:00
pipeline.h pipeline: switch some code over to functions 2015-05-18 09:33:47 +02:00
pop3.c
pop3.h
progress.c
progress.h
rawstr.c
rawstr.h
rtsp.c rtsp: support basic/digest authentication 2015-08-20 23:02:28 +02:00
rtsp.h
security.c security:choose_mech fix DEAD CODE warning 2015-06-15 09:02:46 +02:00
select.c
select.h
sendf.c CURLMOPT_PIPELINE: bit 1 is for multiplexing 2015-05-18 08:57:18 +02:00
sendf.h
setup-os400.h
setup-vms.h openssl: VMS support for SHA256 2015-07-14 01:25:36 -04:00
share.c share_init: fix OOM crash 2015-05-22 16:26:14 +02:00
share.h hostcache: made all host caches use structs, not pointers 2015-05-12 09:46:53 +02:00
sigpipe.h
slist.c
slist.h
smb.c SMB: rangecheck values read off incoming packet 2015-06-17 07:43:13 +02:00
smb.h
smtp.c
smtp.h
sockaddr.h
socks_gssapi.c
socks_sspi.c
socks.c build: fix failures with -Wcast-align and -Werror 2015-09-26 23:10:20 +02:00
socks.h
speedcheck.c
speedcheck.h
splay.c
splay.h
ssh.c fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
ssh.h
strdup.c
strdup.h
strequal.c
strequal.h
strerror.c curl_sspi: fix possibly undefined CRYPT_E_REVOKED 2015-09-10 02:17:33 -04:00
strerror.h
strtok.c
strtok.h
strtoofft.c
strtoofft.h
telnet.c fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
telnet.h
tftp.c
tftp.h
timeval.c
timeval.h
transfer.c fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
transfer.h fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
url.c fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
url.h http2: init the pushed transfer properly 2015-06-24 23:44:42 +02:00
urldata.h fread_func: move callback pointer from set to state struct 2015-10-15 23:32:19 +02:00
version.c
warnless.c
warnless.h
wildcard.c
wildcard.h
x509asn1.c cyassl: Implement public key pinning 2015-04-22 17:07:19 -04:00
x509asn1.h cyassl: Implement public key pinning 2015-04-22 17:07:19 -04:00