msvcrt: Be less strict while parsing file open mode in fopen function.
This commit is contained in:
parent
fc8dfe60ea
commit
5515170d13
|
@ -1263,6 +1263,8 @@ static int msvcrt_get_flags(const MSVCRT_wchar_t* mode, int *open_flags, int* st
|
||||||
|
|
||||||
TRACE("%s\n", debugstr_w(mode));
|
TRACE("%s\n", debugstr_w(mode));
|
||||||
|
|
||||||
|
while(*mode == ' ') mode++;
|
||||||
|
|
||||||
switch(*mode++)
|
switch(*mode++)
|
||||||
{
|
{
|
||||||
case 'R': case 'r':
|
case 'R': case 'r':
|
||||||
|
@ -1301,6 +1303,8 @@ static int msvcrt_get_flags(const MSVCRT_wchar_t* mode, int *open_flags, int* st
|
||||||
break;
|
break;
|
||||||
case '+':
|
case '+':
|
||||||
case ' ':
|
case ' ':
|
||||||
|
case 'a':
|
||||||
|
case 'w':
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
MSVCRT_INVALID_PMT(0, MSVCRT_EINVAL);
|
MSVCRT_INVALID_PMT(0, MSVCRT_EINVAL);
|
||||||
|
|
Loading…
Reference in New Issue