msvcrt: Improved _getmaxstdio and _setmaxstdio implementation.
This commit is contained in:
parent
19c4c37a1d
commit
2ca229dec1
|
@ -3766,20 +3766,19 @@ int CDECL MSVCRT_wprintf_s(const MSVCRT_wchar_t *format, ...)
|
||||||
*/
|
*/
|
||||||
int CDECL _getmaxstdio(void)
|
int CDECL _getmaxstdio(void)
|
||||||
{
|
{
|
||||||
FIXME("stub, always returns 512\n");
|
return MSVCRT_max_streams;
|
||||||
return 512;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*********************************************************************
|
/*********************************************************************
|
||||||
* _setmaxstdio_ (MSVCRT.@)
|
* _setmaxstdio (MSVCRT.@)
|
||||||
*/
|
*/
|
||||||
int CDECL _setmaxstdio(int newmax)
|
int CDECL _setmaxstdio(int newmax)
|
||||||
{
|
{
|
||||||
int res;
|
TRACE("%d\n", newmax);
|
||||||
if( newmax > 2048)
|
|
||||||
res = -1;
|
if(newmax<_IOB_ENTRIES || newmax>MSVCRT_MAX_FILES || newmax<MSVCRT_stream_idx)
|
||||||
else
|
return -1;
|
||||||
res = newmax;
|
|
||||||
FIXME("stub: setting new maximum for number of simultaneously open files not implemented,returning %d\n",res);
|
MSVCRT_max_streams = newmax;
|
||||||
return res;
|
return MSVCRT_max_streams;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue