Skip to content

Commit

Permalink
lib-sieve: util: edit-mail: Fixed potential NULL dereference in edit_…
Browse files Browse the repository at this point in the history
…mail_istream_seek().

Used the stream's cur_header field, rather than the local variable.
Problem found by Coverity.
  • Loading branch information
stephanbosch committed Nov 25, 2017
1 parent 1e20fa6 commit c9cf565
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib-sieve/util/edit-mail.c
Expand Up @@ -2109,7 +2109,7 @@ static void edit_mail_istream_seek
offset += cur_header->field->size;

while ( v_offset > offset ) {
cur_header = edstream->cur_header->next;
cur_header = cur_header->next;
i_assert( cur_header != NULL );

edstream->cur_header_v_offset = offset;
Expand Down

0 comments on commit c9cf565

Please sign in to comment.