app: take into account possibility of NULL error.
Normally the error should not be NULL if file_open_layers() returns no layers. But just in case, in order not to crash when we could avoid it, let's double-check.
This commit is contained in:
parent
85a9af435a
commit
76a255caa1
1 changed files with 1 additions and 1 deletions
|
|
@ -298,7 +298,7 @@ file_open_dialog_open_layers (GtkWidget *dialog,
|
|||
{
|
||||
gimp_message (image->gimp, G_OBJECT (dialog), GIMP_MESSAGE_ERROR,
|
||||
_("Opening '%s' failed:\n\n%s"),
|
||||
gimp_file_get_utf8_name (file), error->message);
|
||||
gimp_file_get_utf8_name (file), error ? error->message: _("n/a"));
|
||||
g_clear_error (&error);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue