From: Jay Satiro Date: Sun, 2 Mar 2025 20:12:27 +0000 (-0500) Subject: ftp: fix comment X-Git-Tag: curl-8_13_0~289 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9a0767017c64555f3c2797fdaabfbbb7b6eaaca1;p=thirdparty%2Fcurl.git ftp: fix comment - Explain ftp_conn's newhost and newport in the struct definition. Follow-up to 1485e892 which changed the order of some struct members to reduce struct size. Closes https://github.com/curl/curl/pull/16538 --- diff --git a/lib/ftp.h b/lib/ftp.h index 10d62e28c7..bf6542a5bd 100644 --- a/lib/ftp.h +++ b/lib/ftp.h @@ -125,7 +125,8 @@ struct ftp_conn { char *entrypath; /* the PWD reply when we logged on */ char *file; /* url-decoded filename (or path) */ char **dirs; /* realloc()ed array for path components */ - char *newhost; + char *newhost; /* the (allocated) IP addr or hostname to connect the data + connection to */ char *prevpath; /* url-decoded conn->path from the previous transfer */ char transfertype; /* set by ftp_transfertype for use by Curl_client_write()a and others (A/I or zero) */ @@ -139,9 +140,8 @@ struct ftp_conn { int count1; /* general purpose counter for the state machine */ int count2; /* general purpose counter for the state machine */ int count3; /* general purpose counter for the state machine */ - /* newhost is the (allocated) IP addr or hostname to connect the data - connection to */ - unsigned short newport; + unsigned short newport; /* the port of 'newhost' to connect the data + connection to */ ftpstate state; /* always use ftp.c:state() to change state! */ ftpstate state_saved; /* transfer type saved to be reloaded after data connection is established */