Skip to content

Commit 2ab50b5

Browse files
committed
update branch-1.4
1 parent de969bf commit 2ab50b5

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/cfl_dialog.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ void Fl_Native_File_Chooser_delete(Fl_Native_File_Chooser *self) {
2727

2828
const char *Fl_Native_File_Chooser_filename(Fl_Native_File_Chooser *self) {
2929
LOCK(const char *x = self->filename());
30-
if (!strcmp(x, ""))
30+
if (!x || !strcmp(x, ""))
3131
return nullptr;
3232
else
3333
return x;
@@ -36,7 +36,7 @@ const char *Fl_Native_File_Chooser_filename(Fl_Native_File_Chooser *self) {
3636
const char *
3737
Fl_Native_File_Chooser_filenames(Fl_Native_File_Chooser *self, int cnt) {
3838
LOCK(const char *x = self->filename(cnt));
39-
if (!strcmp(x, ""))
39+
if (!x || !strcmp(x, ""))
4040
return nullptr;
4141
else
4242
return x;

0 commit comments

Comments
 (0)