aboutsummaryrefslogtreecommitdiff
path: root/lib/ftplistparser.c
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2010-06-09 16:48:19 +0200
committerYang Tse <yangsita@gmail.com>2010-06-09 16:48:19 +0200
commit343c4c7072cd5ee16f1e444089db8c7e2ad92430 (patch)
tree40672bc11a56976a29a3ec0b738d3965d7f83bd3 /lib/ftplistparser.c
parent6a0d3233ffacec92ad230f74458454bf65a24eac (diff)
code simplification
Diffstat (limited to 'lib/ftplistparser.c')
-rw-r--r--lib/ftplistparser.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/lib/ftplistparser.c b/lib/ftplistparser.c
index 3dd661788..08a794294 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));
}