- Added Zloba's fix for Linux's I_FindFirst.

SVN r63 (trunk)
This commit is contained in:
Christoph Oelckers 2006-04-22 15:02:08 +00:00
parent 663a0f5209
commit 9aae758ec5
2 changed files with 13 additions and 1 deletions

View File

@ -1,3 +1,6 @@
April 21, 2006 (Changes by Graf Zahl)
- Added Zloba's fix for Linux's I_FindFirst.
April 20, 2006 (Changes by Graf Zahl)
- Fixed: Doom's status bar assumed that STBAR was always in Doom patch format.
- Added MF3_DONTSPLASH to the newly created sound sequence things.

View File

@ -61,6 +61,7 @@
#include "stats.h"
#include "hardware.h"
#include "zstring.h"
EXTERN_CVAR (String, language)
@ -385,14 +386,22 @@ static int matchfile (const struct dirent *ent)
void *I_FindFirst (const char *filespec, findstate_t *fileinfo)
{
string dir;
char *slash = strrchr (filespec, '/');
if (slash)
{
pattern = slash+1;
dir = string(filespec, slash-filespec+1);
}
else
{
pattern = filespec;
dir = ".";
}
fileinfo->current = 0;
fileinfo->count = scandir (".", &fileinfo->namelist,
fileinfo->count = scandir (dir.GetChars(), &fileinfo->namelist,
matchfile, alphasort);
if (fileinfo->count > 0)
{