mirror of
https://github.com/reactos/reactos.git
synced 2025-08-06 02:03:13 +00:00
[CRT] Apply Wine commit 21fd1d3 by Nikolay Sivov: Fix calloc() prototype. CORE-11866
svn path=/trunk/; revision=72544
This commit is contained in:
parent
7dfe459bdf
commit
af3b7ffad5
3 changed files with 5 additions and 5 deletions
|
@ -410,7 +410,7 @@ unsigned create_io_inherit_block(WORD *size, BYTE **block)
|
||||||
ioinfo* fdinfo;
|
ioinfo* fdinfo;
|
||||||
|
|
||||||
*size = sizeof(unsigned) + (sizeof(char) + sizeof(HANDLE)) * fdend;
|
*size = sizeof(unsigned) + (sizeof(char) + sizeof(HANDLE)) * fdend;
|
||||||
*block = calloc(*size, 1);
|
*block = calloc(1, *size);
|
||||||
if (!*block)
|
if (!*block)
|
||||||
{
|
{
|
||||||
*size = 0;
|
*size = 0;
|
||||||
|
@ -547,7 +547,7 @@ int CDECL _isatty(int fd)
|
||||||
&& _isatty(file->_file))
|
&& _isatty(file->_file))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
file->_base = calloc(MSVCRT_INTERNAL_BUFSIZ,1);
|
file->_base = calloc(1, MSVCRT_INTERNAL_BUFSIZ);
|
||||||
if(file->_base) {
|
if(file->_base) {
|
||||||
file->_bufsiz = MSVCRT_INTERNAL_BUFSIZ;
|
file->_bufsiz = MSVCRT_INTERNAL_BUFSIZ;
|
||||||
file->_flag |= _IOMYBUF;
|
file->_flag |= _IOMYBUF;
|
||||||
|
|
|
@ -69,7 +69,7 @@ _onexit_t CDECL _onexit(_onexit_t func)
|
||||||
{
|
{
|
||||||
_onexit_t *newtable;
|
_onexit_t *newtable;
|
||||||
TRACE("expanding table\n");
|
TRACE("expanding table\n");
|
||||||
newtable = calloc(sizeof(void *),atexit_table_size + 32);
|
newtable = calloc(atexit_table_size + 32, sizeof(void *));
|
||||||
if (!newtable)
|
if (!newtable)
|
||||||
{
|
{
|
||||||
TRACE("failed!\n");
|
TRACE("failed!\n");
|
||||||
|
|
|
@ -288,9 +288,9 @@ size_t CDECL _msize(void* mem)
|
||||||
/*********************************************************************
|
/*********************************************************************
|
||||||
* calloc (MSVCRT.@)
|
* calloc (MSVCRT.@)
|
||||||
*/
|
*/
|
||||||
void* CDECL calloc(size_t size, size_t count)
|
void* CDECL calloc(size_t count, size_t size)
|
||||||
{
|
{
|
||||||
return HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, size * count );
|
return HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, count * size );
|
||||||
}
|
}
|
||||||
|
|
||||||
/*********************************************************************
|
/*********************************************************************
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue