Skip to content
Commit d4c320a5 authored by Dmitry Safonov's avatar Dmitry Safonov Committed by Pavel Emelyanov
Browse files

pagemap: init pagemap entries array as NULL



There is call to close_page_read on open_pages_image_at failure,
also on failure of init_pagemaps. pmes[] is uninitialized here
and free_pagemaps() will try to walk them and call xfree().
Which surely would lead to crash.

pagemap.c:317:6: warning: Branch condition evaluates to a garbage value
        if (pr->pmes)
            ^~~~~~~~

Signed-off-by: default avatarDmitry Safonov <dsafonov@virtuozzo.com>
Signed-off-by: default avatarPavel Emelyanov <xemul@virtuozzo.com>
parent 27994548
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment