retcode = Curl_ftp_nextconnect(conn);
else
/* since we didn't connect now, we want do_more to get called */
- conn->do_more = TRUE;
+ conn->bits.do_more = TRUE;
}
return retcode;
conn->allocptr.cookie = aprintf("Cookie: %s\015\012", data->set.cookie);
}
- if(conn->upload_chunky) {
+ if(conn->bits.upload_chunky) {
if(!checkheaders(data, "Transfer-Encoding:")) {
te = "Transfer-Encoding: chunked\r\n";
}
if(CURLE_OK == easy->result) {
/* after do, go PERFORM... or DO_MORE */
- if(easy->easy_conn->do_more) {
+ if(easy->easy_conn->bits.do_more) {
/* we're supposed to do more, but we need to sit down, relax
and wait a little while first */
easy->state = CURLM_STATE_DO_MORE;
if(!k->upload_done) {
- if(conn->upload_chunky) {
+ if(conn->bits.upload_chunky) {
/* if chunked Transfer-Encoding */
buffersize -= (8 + 2 + 2); /* 32bit hex + CRLF + CRLF */
conn->upload_fromhere += 10; /* 32bit hex + CRLF */
nread = data->set.fread(conn->upload_fromhere, 1,
buffersize, data->set.in);
- if(conn->upload_chunky) {
+ if(conn->bits.upload_chunky) {
/* if chunked Transfer-Encoding */
char hexbuffer[9];
int hexlen = snprintf(hexbuffer, sizeof(hexbuffer),
Curl_pgrsSetUploadCounter(data, 0);
Curl_pgrsSetDownloadCounter(data, 0);
- if (!conn->getheader) {
+ if (!conn->bits.getheader) {
k->header = FALSE;
if(conn->size > 0)
Curl_pgrsSetDownloadSize(data, conn->size);
}
/* we want header and/or body, if neither then don't do this! */
- if(conn->getheader || !data->set.no_body) {
+ if(conn->bits.getheader || !data->set.no_body) {
FD_ZERO (&k->readfd); /* clear it */
if(conn->sockfd != -1) {
return CURLE_OK;
/* we want header and/or body, if neither then don't do this! */
- if(!conn->getheader && data->set.no_body)
+ if(!conn->bits.getheader && data->set.no_body)
return CURLE_OK;
k->writefdp = &k->writefd; /* store the address of the set */
/* now copy all input parameters */
conn->sockfd = sockfd;
conn->size = size;
- conn->getheader = getheader;
+ conn->bits.getheader = getheader;
conn->bytecountp = bytecountp;
conn->writesockfd = writesockfd;
conn->writebytecountp = writebytecountp;
is later set "for real" using Curl_pgrsStartNow(). */
conn->data->progress.start = conn->created;
- conn->upload_chunky =
+ conn->bits.upload_chunky =
((conn->protocol&PROT_HTTP) &&
data->set.upload &&
(data->set.infilesize == -1) &&
struct connectdata *conn = *connp;
struct SessionHandle *data=conn->data;
- conn->do_more = FALSE; /* by default there's no curl_do_more() to use */
+ conn->bits.do_more = FALSE; /* by default there's no curl_do_more() to use */
if(conn->curl_do) {
/* generic protocol-specific function pointer set in curl_connect() */
IP address */
bool use_range;
bool rangestringalloc; /* the range string is malloc()'ed */
+
+ bool do_more; /* this is set TRUE if the ->curl_do_more() function is
+ supposed to be called, after ->curl_do() */
+
+ bool upload_chunky; /* set TRUE if we are doing chunked transfer-encoding
+ on upload */
+
+ bool getheader; /* TRUE if header parsing is wanted */
};
/*
/* READ stuff */
int sockfd; /* socket to read from or -1 */
int size; /* -1 if unknown at this point */
- bool getheader; /* TRUE if header parsing is wanted */
long *bytecountp; /* return number of bytes read or NULL */
/* WRITE stuff */
and the 'upload_present' contains the number of bytes available at this
position */
char *upload_fromhere;
-
- bool do_more; /* this is set TRUE if the ->curl_do_more() function is
- supposed to be called, after ->curl_do() */
-
- bool upload_chunky; /* set TRUE if we are doing chunked transfer-encoding
- on upload */
};
/* The end of connectdata. 08/27/02 jhrg */