FLTK logo

[Library] r5746 - trunk/src

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 All Forums  |  Back to fltk.commit  ]
 
Previous Message ]Next Message ]

[Library] r5746 - trunk/src fltk-dev Mar 15, 2007  
 
Author: spitzak
Date: 2007-03-15 14:31:52 -0500 (Thu, 15 Mar 2007)
New Revision: 5746
Log:
Unix version of filename_list was adding slash after the directories,
but the Windows version does not do this, despite claims to the contrary.
This wasted time in stat and broke programs that relied on the previous
behavior of filename_list. File chooser still seems to work about the
same, though no slashes are after the directory names.


Modified:
   trunk/src/filename_list.cxx

Modified: trunk/src/filename_list.cxx
===================================================================
--- trunk/src/filename_list.cxx	2007-03-15 13:27:41 UTC (rev 5745)
+++ trunk/src/filename_list.cxx	2007-03-15 19:31:52 UTC (rev 5746)
@@ -80,8 +80,10 @@
   int n = scandir(d, list, 0, (int(*)(const void*,const void*))sort);
 #endif
 
+#if 0 // Add a slash to all directories...
 #if defined(WIN32) && !defined(__CYGWIN__)
   // we did this already during fl_scandir/win32
+  // WAS: no it isn't!
 #else
   // append a '/' to all filenames that are directories
   int i, dirlen = strlen(d);
@@ -105,6 +107,8 @@
   }
   free(fullname);
 #endif
+#endif
+
   return n;
 }
 

Direct Link to Message ]
 
     
Previous Message ]Next Message ]
 
 

Comments are owned by the poster. All other content is copyright 1998-2024 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.