Skip to content

Commit

Permalink
doveadm: Extra safety - initialize cmd_input_fd to -1
Browse files Browse the repository at this point in the history
Just to be sure it's never attempted to be accessed as 0 (stdin) before
being initialized. (It didn't happen with current code as far as I know.)
  • Loading branch information
sirainen committed Aug 8, 2016
1 parent 4a4f7ff commit 25c2147
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/doveadm/doveadm-mail.c
Expand Up @@ -125,6 +125,7 @@ doveadm_mail_cmd_alloc_size(size_t size)
pool = pool_alloconly_create("doveadm mail cmd", 1024);
ctx = p_malloc(pool, size);
ctx->pool = pool;
ctx->cmd_input_fd = -1;
return ctx;
}

Expand Down

0 comments on commit 25c2147

Please sign in to comment.