mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-22 03:02:06 +03:00
From ticket #3116: fix segfault in cpio VFS while reading corrupted RPM.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
198334ccc4
commit
65b83b3efc
@ -787,7 +787,8 @@ cpio_super_same (const vfs_path_element_t * vpath_element, struct vfs_s_super *p
|
||||
return 0;
|
||||
|
||||
/* Has the cached archive been changed on the disk? */
|
||||
if (((cpio_super_data_t *) parc->data)->st.st_mtime < archive_stat->st_mtime)
|
||||
if (parc->data != NULL
|
||||
&& ((cpio_super_data_t *) parc->data)->st.st_mtime < archive_stat->st_mtime)
|
||||
{
|
||||
/* Yes, reload! */
|
||||
(*vfs_cpiofs_ops.free) ((vfsid) parc);
|
||||
|
Loading…
Reference in New Issue
Block a user