mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-03 01:54:24 +03:00
Merge branch '4560_extfs_open_deleted_archive'
* 4560_extfs_open_deleted_archive: Ticket #4560: extfs: fix segfault om enter to deleted archive.
This commit is contained in:
commit
b68243df1e
@ -531,7 +531,10 @@ extfs_open_archive (int fstype, const char *name, struct extfs_super_t **pparc,
|
||||
if (info->need_archive)
|
||||
{
|
||||
if (mc_stat (name_vpath, &mystat) == -1)
|
||||
{
|
||||
mc_propagate_error (error, 0, "%s", unix_error_string (errno));
|
||||
goto ret;
|
||||
}
|
||||
|
||||
if (!vfs_file_is_local (name_vpath))
|
||||
{
|
||||
@ -737,9 +740,14 @@ extfs_open_and_read_archive (int fstype, const char *name, struct extfs_super_t
|
||||
const extfs_plugin_info_t *info;
|
||||
|
||||
info = &g_array_index (extfs_plugins, extfs_plugin_info_t, fstype);
|
||||
message (D_ERROR, MSG_ERROR, _("Cannot open %s archive\n%s:\n%s"), info->prefix, name,
|
||||
error->message);
|
||||
g_error_free (error);
|
||||
if (error == NULL)
|
||||
message (D_ERROR, MSG_ERROR, _("Cannot open %s archive\n%s"), info->prefix, name);
|
||||
else
|
||||
{
|
||||
message (D_ERROR, MSG_ERROR, _("Cannot open %s archive\n%s:\n%s"), info->prefix, name,
|
||||
error->message);
|
||||
g_error_free (error);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user