From 1b77967823a8048eb8f0af2ee2da2fe4fcea7fab Mon Sep 17 00:00:00 2001 From: ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> Date: Fri, 23 Aug 2019 14:16:13 +0200 Subject: Add check useful with macOS 10.15 public beta (Catalina). --- src/Fl_Native_File_Chooser_MAC.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Fl_Native_File_Chooser_MAC.mm') diff --git a/src/Fl_Native_File_Chooser_MAC.mm b/src/Fl_Native_File_Chooser_MAC.mm index 26aee3a7c..48d489f1e 100644 --- a/src/Fl_Native_File_Chooser_MAC.mm +++ b/src/Fl_Native_File_Chooser_MAC.mm @@ -410,7 +410,7 @@ int Fl_Quartz_Native_File_Chooser_Driver::get_saveas_basename(void) { if (strcmp(d, "/") == 0) l = 1; int lu = strlen(UNLIKELYPREFIX); // Remove UNLIKELYPREFIX between directory and filename parts - memmove(q + l, q + l + lu, strlen(q + l + lu) + 1); + if (memcmp(q+l, UNLIKELYPREFIX, lu) == 0) memmove(q + l, q + l + lu, strlen(q + l + lu) + 1); } set_single_pathname( q ); free(q); -- cgit v1.2.3