aboutsummaryrefslogtreecommitdiff
path: root/lib/ftp.c
diff options
context:
space:
mode:
authorDan Fandrich <dan@coneharvesters.com>2007-07-20 00:41:12 +0000
committerDan Fandrich <dan@coneharvesters.com>2007-07-20 00:41:12 +0000
commit4a2f0fb2beb95b2edccead115a92971643bd5297 (patch)
treeaa540c5a7d6ee471db954dfaa131c112cd5de475 /lib/ftp.c
parentdca3564cfbe636f9937949b7127a39f6ffac2bdf (diff)
Made some const arrays static to avoid unnecessary stack usage.
Diffstat (limited to 'lib/ftp.c')
-rw-r--r--lib/ftp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/ftp.c b/lib/ftp.c
index dcea9ad0c..932c8c8dc 100644
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -705,7 +705,7 @@ static void state(struct connectdata *conn,
{
#if defined(CURLDEBUG) && !defined(CURL_DISABLE_VERBOSE_STRINGS)
/* for debug purposes */
- const char *names[]={
+ static const char *names[]={
"STOP",
"WAIT220",
"AUTH",
@@ -862,7 +862,7 @@ static CURLcode ftp_state_use_port(struct connectdata *conn,
char hbuf[NI_MAXHOST];
struct sockaddr *sa=(struct sockaddr *)&ss;
char tmp[1024];
- const char *mode[] = { "EPRT", "PORT", NULL };
+ static const char *mode[] = { "EPRT", "PORT", NULL };
int rc;
int error;
char *host=NULL;
@@ -1246,7 +1246,7 @@ static CURLcode ftp_state_use_pasv(struct connectdata *conn)
*/
- const char *mode[] = { "EPSV", "PASV", NULL };
+ static const char *mode[] = { "EPSV", "PASV", NULL };
int modeoff;
#ifdef PF_INET6