aboutsummaryrefslogtreecommitdiff
path: root/lib/pop3.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/pop3.c')
-rw-r--r--lib/pop3.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/pop3.c b/lib/pop3.c
index 9eaa09b6c..80cf139b3 100644
--- a/lib/pop3.c
+++ b/lib/pop3.c
@@ -1272,16 +1272,17 @@ static CURLcode pop3_block_statemach(struct connectdata *conn)
required */
static CURLcode pop3_init(struct connectdata *conn)
{
+ CURLcode result = CURLE_OK;
struct SessionHandle *data = conn->data;
struct POP3 *pop3 = data->state.proto.pop3;
if(!pop3) {
pop3 = data->state.proto.pop3 = calloc(sizeof(struct POP3), 1);
if(!pop3)
- return CURLE_OUT_OF_MEMORY;
+ result = CURLE_OUT_OF_MEMORY;
}
- return CURLE_OK;
+ return result;
}
/* For the POP3 "protocol connect" and "doing" phases only */