diff options
author | Kamil Dudka <kdudka@redhat.com> | 2010-11-19 13:43:20 +0100 |
---|---|---|
committer | Kamil Dudka <kdudka@redhat.com> | 2010-12-06 14:35:42 +0100 |
commit | 5c7c9a768d009319520142fcaee1dea33625060f (patch) | |
tree | a8c31c739426e32edb76d9b86be951d9cb1191da /lib/tftp.c | |
parent | bf1c102b80698e60972063b269f61ccbe2bfeaa8 (diff) | |
download | curl-5c7c9a768d009319520142fcaee1dea33625060f.tar.gz |
url: provide dead_connection flag in Curl_handler::disconnect
It helps to prevent a hangup with some FTP servers in case idle session
timeout has exceeded. But it may be useful also for other protocols
that send any quit message on disconnect. Currently used by FTP, POP3,
IMAP and SMTP.
Diffstat (limited to 'lib/tftp.c')
-rw-r--r-- | lib/tftp.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/tftp.c b/lib/tftp.c index 46ed2a71e..fc741c941 100644 --- a/lib/tftp.c +++ b/lib/tftp.c @@ -166,7 +166,7 @@ typedef struct tftp_state_data { static CURLcode tftp_rx(tftp_state_data_t *state, tftp_event_t event) ; static CURLcode tftp_tx(tftp_state_data_t *state, tftp_event_t event) ; static CURLcode tftp_connect(struct connectdata *conn, bool *done); -static CURLcode tftp_disconnect(struct connectdata *conn); +static CURLcode tftp_disconnect(struct connectdata *conn, bool dead_connection); static CURLcode tftp_do(struct connectdata *conn, bool *done); static CURLcode tftp_done(struct connectdata *conn, CURLcode, bool premature); @@ -925,9 +925,10 @@ static CURLcode tftp_state_machine(tftp_state_data_t *state, * The disconnect callback * **********************************************************/ -static CURLcode tftp_disconnect(struct connectdata *conn) +static CURLcode tftp_disconnect(struct connectdata *conn, bool dead_connection) { tftp_state_data_t *state = conn->proto.tftpc; + (void) dead_connection; /* done, free dynamically allocated pkt buffers */ if(state) { |