diff options
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/nativefilechooser-simple-app.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/nativefilechooser-simple-app.cxx b/examples/nativefilechooser-simple-app.cxx index e22aa40ac..cb35bcfd6 100644 --- a/examples/nativefilechooser-simple-app.cxx +++ b/examples/nativefilechooser-simple-app.cxx @@ -31,7 +31,7 @@ class Application : public Fl_Window { Fl_Native_File_Chooser *fc; // Does file exist? int exist(const char *filename) { - FILE *fp = fopen(filename, "r"); + FILE *fp = fl_fopen(filename, "r"); if (fp) { fclose(fp); return(1); } else { return(0); } } @@ -46,7 +46,7 @@ class Application : public Fl_Window { void save(const char *filename) { printf("Saving '%s'\n", filename); if ( !exist(filename) ) { - FILE *fp = fopen(filename, "w"); // create file if it doesn't exist + FILE *fp = fl_fopen(filename, "w"); // create file if it doesn't exist if ( fp ) { // A real app would do something useful here. fprintf(fp, "Hello world.\n"); |
