smtp_connect: always provide host name buffer

Previously the host name buffer was only used if gethostname() exists,
but since we converted that into a curl private function that function
always exists and will be used so the buffer needs to exist for all
cases/systems.
This commit is contained in:
Daniel Stenberg 2010-07-30 22:36:31 +02:00
parent d296dd4ee8
commit 314117cbf1

View File

@ -1042,10 +1042,7 @@ static CURLcode smtp_connect(struct connectdata *conn,
struct pingpong *pp=&smtpc->pp;
const char *path = conn->data->state.path;
int len;
#ifdef HAVE_GETHOSTNAME
char localhost[1024 + 1];
#endif
char localhost[1024 + 1];
*done = FALSE; /* default to not done yet */