Implementation of _get_sbh_threshold and _set_sbh_threshold

functions.
This commit is contained in:
Vijay Kiran Kamuju 2005-09-23 10:07:05 +00:00 committed by Alexandre Julliard
parent 106af86740
commit 07b53de0b2
3 changed files with 27 additions and 2 deletions

View File

@ -39,6 +39,8 @@ static int MSVCRT_new_mode;
/* FIXME - According to documentation it should be 8*1024, at runtime it returns 16 */
static unsigned int MSVCRT_amblksiz = 16;
/* FIXME - According to documentation it should be 480 bytes, at runtime default is 0 */
static size_t MSVCRT_sbh_threshold = 0;
/*********************************************************************
* ??2@YAPAXI@Z (MSVCRT.@)
@ -291,3 +293,23 @@ unsigned int* __p__amblksiz(void)
{
return &MSVCRT_amblksiz;
}
/*********************************************************************
* _get_sbh_threshold (MSVCRT.@)
*/
size_t _get_sbh_threshold(void)
{
return MSVCRT_sbh_threshold;
}
/*********************************************************************
* _set_sbh_threshold (MSVCRT.@)
*/
int _set_sbh_threshold(size_t threshold)
{
if(threshold > 1016)
return 0;
else
MSVCRT_sbh_threshold = threshold;
return 1;
}

View File

@ -248,7 +248,7 @@
@ cdecl _futime(long ptr)
@ cdecl _gcvt(double long str)
@ cdecl _get_osfhandle(long)
@ stub _get_sbh_threshold #()
@ cdecl _get_sbh_threshold()
@ cdecl _getch()
@ cdecl _getche()
@ cdecl _getcwd(str long)
@ -424,7 +424,7 @@
@ cdecl _searchenv(str str ptr)
@ stdcall -i386 _seh_longjmp_unwind(ptr)
@ cdecl _set_error_mode(long)
@ stub _set_sbh_threshold #(long)
@ cdecl _set_sbh_threshold(long)
@ cdecl _seterrormode(long)
@ cdecl -i386 _setjmp(ptr) MSVCRT__setjmp
@ cdecl -i386 _setjmp3(ptr long) MSVCRT__setjmp3

View File

@ -71,6 +71,9 @@ void free(void*);
void* malloc(size_t);
void* realloc(void*,size_t);
size_t _get_sbh_threshold(void);
int _set_sbh_threshold(size_t size);
#ifdef __cplusplus
}
#endif