Skip to content

Commit

Permalink
Fix FINDFILE_DTA to capitalize
Browse files Browse the repository at this point in the history
  • Loading branch information
otya128 committed Oct 10, 2018
1 parent 6fab8e0 commit 6e22d12
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions krnl386/int21.c
Original file line number Diff line number Diff line change
Expand Up @@ -3955,11 +3955,15 @@ static BOOL INT21_FindNext( CONTEXT *context )
dta->fileattr = entry.dwFileAttributes;
dta->filesize = entry.nFileSizeLow;
FileTimeToDosDateTime( &entry.ftLastWriteTime, &dta->filedate, &dta->filetime );
memset(dta->filename, 0, 13);
if (entry.cAlternateFileName[0])
WideCharToMultiByte(CP_OEMCP, 0, entry.cAlternateFileName, -1,
dta->filename, 13, NULL, NULL);
else
WideCharToMultiByte(CP_OEMCP, 0, entry.cFileName, -1, dta->filename, 13, NULL, NULL);
/* shoud be UPPER CASE */
for (int i = 0; i < 13; i++)
dta->filename[i] = toupper(dta->filename[i]);

if (!memchr(dta->mask,'?',11))
{
Expand Down

0 comments on commit 6e22d12

Please sign in to comment.