Oops, the change to filename_list broke Irix, which defined the scandir

in the original way.  I hope this fix was not a mistake, not sure how
many different systems need it each way, but I was trying to make the
most common case the default.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@996 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Bill Spitzak 2000-01-27 08:27:26 +00:00
parent 53919249e2
commit d37850b115

View File

@ -1,5 +1,5 @@
//
// "$Id: filename_list.cxx,v 1.10.2.3 2000/01/26 06:27:15 bill Exp $"
// "$Id: filename_list.cxx,v 1.10.2.4 2000/01/27 08:27:26 bill Exp $"
//
// Filename list routines for the Fast Light Tool Kit (FLTK).
//
@ -43,18 +43,18 @@ int filename_list(const char *d, dirent ***list) {
#if defined(__hpux)
// HP-UX defines the comparison function like this:
return scandir(d, list, 0, (int(*)(const dirent **, const dirent **))numericsort);
#elif HAVE_SCANDIR
#elif HAVE_SCANDIR && !defined(__sgi)
// The vast majority of Unix systems want the sort function to have this
// prototype, most likely so that it can be passed to qsort without any
// changes:
return scandir(d, list, 0, (int(*)(const void*,const void*))numericsort);
#else
// This version is when we define our own scandir (WIN32 and perhaps
// some Unix systems). This may be necessary for some Unix systems:
// some Unix systems) and apparently on Irix:
return scandir(d, list, 0, numericsort);
#endif
}
//
// End of "$Id: filename_list.cxx,v 1.10.2.3 2000/01/26 06:27:15 bill Exp $".
// End of "$Id: filename_list.cxx,v 1.10.2.4 2000/01/27 08:27:26 bill Exp $".
//