diff --git a/lib/ftplistparser.c b/lib/ftplistparser.c index 3dd66178862691323658f17d11dadb6eee706f69..08a794294ac6380d367fd4927a03214ecce4f9db 100644 --- a/lib/ftplistparser.c +++ b/lib/ftplistparser.c @@ -190,12 +190,7 @@ struct ftp_parselist_data { struct ftp_parselist_data *Curl_ftp_parselist_data_alloc(void) { - struct ftp_parselist_data *parselist_data = - malloc(sizeof(struct ftp_parselist_data)); - if(!parselist_data) - return ZERO_NULL; - memset(parselist_data, 0, sizeof(struct ftp_parselist_data)); - return parselist_data; + return calloc(1, sizeof(struct ftp_parselist_data)); }