code: style updates

This commit is contained in:
Daniel Stenberg 2016-04-03 20:28:34 +02:00
parent 9d194a1143
commit a71012c03e
85 changed files with 249 additions and 248 deletions

View file

@ -710,7 +710,7 @@ CURLcode Curl_GetFTPResponse(ssize_t *nreadp, /* return number of bytes read */
/* check and reset timeout value every lap */
timeout = Curl_pp_state_timeout(pp);
if(timeout <=0 ) {
if(timeout <=0) {
failf(data, "FTP response timeout");
return CURLE_OPERATION_TIMEDOUT; /* already too little time */
}
@ -1036,7 +1036,7 @@ static CURLcode ftp_state_use_port(struct connectdata *conn,
if(*string_ftpport == '[') {
/* [ipv6]:port(-range) */
ip_start = string_ftpport + 1;
if((ip_end = strchr(string_ftpport, ']')) != NULL )
if((ip_end = strchr(string_ftpport, ']')) != NULL)
strncpy(addr, ip_start, ip_end - ip_start);
}
else
@ -1057,7 +1057,7 @@ static CURLcode ftp_state_use_port(struct connectdata *conn,
else
#endif
/* (ipv4|domain|interface):port(-range) */
strncpy(addr, string_ftpport, ip_end - ip_start );
strncpy(addr, string_ftpport, ip_end - ip_start);
}
else
/* ipv4|interface */
@ -1077,11 +1077,11 @@ static CURLcode ftp_state_use_port(struct connectdata *conn,
/* correct errors like:
* :1234-1230
* :-4711 , in this case port_min is (unsigned)-1,
* :-4711, in this case port_min is (unsigned)-1,
* therefore port_min > port_max for all cases
* but port_max = (unsigned)-1
*/
if(port_min > port_max )
if(port_min > port_max)
port_min = port_max = 0;
@ -1525,12 +1525,12 @@ static CURLcode ftp_state_list(struct connectdata *conn)
}
}
cmd = aprintf( "%s%s%s",
data->set.str[STRING_CUSTOMREQUEST]?
data->set.str[STRING_CUSTOMREQUEST]:
(data->set.ftp_list_only?"NLST":"LIST"),
lstArg? " ": "",
lstArg? lstArg: "" );
cmd = aprintf("%s%s%s",
data->set.str[STRING_CUSTOMREQUEST]?
data->set.str[STRING_CUSTOMREQUEST]:
(data->set.ftp_list_only?"NLST":"LIST"),
lstArg? " ": "",
lstArg? lstArg: "");
if(!cmd) {
free(lstArg);
@ -1652,7 +1652,7 @@ static CURLcode ftp_state_ul_setup(struct connectdata *conn,
/* 4. lower the infilesize counter */
/* => transfer as usual */
if(data->state.resume_from < 0 ) {
if(data->state.resume_from < 0) {
/* Got no given size to start from, figure it out */
PPSENDF(&ftpc->pp, "SIZE %s", ftpc->file);
state(conn, FTP_STOR_SIZE);