aboutsummaryrefslogtreecommitdiff
path: root/lib/ftp.c
diff options
context:
space:
mode:
authorDan Fandrich <dan@coneharvesters.com>2008-10-22 05:46:29 +0000
committerDan Fandrich <dan@coneharvesters.com>2008-10-22 05:46:29 +0000
commit7fc4e8af0a2778f6c017a9a95d64a0c211ea1f55 (patch)
tree4d17b3a942fe657dbe207e063543e898097c8eea /lib/ftp.c
parent4198bb88b64383509a7267411282e20cd867d3e0 (diff)
Changed some arrays of char* to arrays of char[] to reduce data size and
run-time relocations.
Diffstat (limited to 'lib/ftp.c')
-rw-r--r--lib/ftp.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/ftp.c b/lib/ftp.c
index d940a12e0..ca8ef1135 100644
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -880,7 +880,7 @@ static CURLcode ftp_state_use_port(struct connectdata *conn,
char hbuf[NI_MAXHOST];
struct sockaddr *sa=(struct sockaddr *)&ss;
char tmp[1024];
- static const char * const mode[] = { "EPRT", "PORT", NULL };
+ static const char mode[][5] = { "EPRT", "PORT" };
int rc;
int error;
char *host=NULL;
@@ -1266,7 +1266,7 @@ static CURLcode ftp_state_use_pasv(struct connectdata *conn)
*/
- static const char * const mode[] = { "EPSV", "PASV", NULL };
+ static const char mode[][5] = { "EPSV", "PASV" };
int modeoff;
#ifdef PF_INET6
@@ -2550,9 +2550,7 @@ static CURLcode ftp_statemach_act(struct connectdata *conn)
struct SessionHandle *data=conn->data;
int ftpcode;
struct ftp_conn *ftpc = &conn->proto.ftpc;
- static const char * const ftpauth[] = {
- "SSL", "TLS"
- };
+ static const char ftpauth[][4] = { "SSL", "TLS" };
size_t nread = 0;
if(ftpc->sendleft) {