diff options
| author | Manolo Gouy <Manolo> | 2014-06-30 13:39:09 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2014-06-30 13:39:09 +0000 |
| commit | 0f4fa1633d898d91b5426aa44b35879eef51c66b (patch) | |
| tree | 435d03ed92c148ce0f1c35840bcecc3a60cae04f /src/Fl_Native_File_Chooser_WIN32.cxx | |
| parent | e64a8e90e325b5fdffa7939f91041ccd7f558e21 (diff) | |
Changes brought in at r. 10046 make fluid crash when open or saving files with Fl_Native_File_Chooser
on the WIN32 platform.
The filter used by fluid "FLUID files \t*.f[ld]/n" makes Fl_Native_File_Chooser::parse_filter() crash.
The present changes TEMPORARILY avoid this crash, but r. 10046 changes should be closely reviewed.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10215 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Native_File_Chooser_WIN32.cxx')
| -rw-r--r-- | src/Fl_Native_File_Chooser_WIN32.cxx | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/Fl_Native_File_Chooser_WIN32.cxx b/src/Fl_Native_File_Chooser_WIN32.cxx index b0f9013a9..5861f440a 100644 --- a/src/Fl_Native_File_Chooser_WIN32.cxx +++ b/src/Fl_Native_File_Chooser_WIN32.cxx @@ -718,11 +718,12 @@ void Fl_Native_File_Chooser::parse_filter(const char *in) { // Init int nwildcards = 0; - char **wildcards; // parsed wildcards (can be several) + //char **wildcards; // parsed wildcards (can be several) + char *wildcards[80]; // TMP int maxfilters = (strcnt(in, ",|") + 1); // count wildcard seps int t; - wildcards = new char*[maxfilters]; - for ( t=0; t<maxfilters; t++ ) { + //wildcards = new char*[maxfilters]; + for ( t=0; t<80/*maxfilters*/; t++ ) { wildcards[t] = new char[slen]; wildcards[t][0] = '\0'; } @@ -791,8 +792,8 @@ void Fl_Native_File_Chooser::parse_filter(const char *in) { delete[] wildprefix; delete[] comp; delete[] name; - for ( t=0; t<maxfilters; t++ ) delete[] wildcards[t]; - delete[] wildcards; + for ( t=0; t<80/*maxfilters*/; t++ ) delete[] wildcards[t]; + //delete[] wildcards; return; } continue; // not done yet, more filters |
