Re: [PATCH] JanitorialProjects/ReplaceMalloc: remove malloc and free from dlls folder

2010-12-30 Thread James McKenzie

On 12/30/10 5:02 AM, Yegor Yefremov wrote:

Hello,

it's my first contribution to wine, so I wanted to start with some
simple task. After fixing the files mentioned in the attached patch,
following files in dlls folder still contain malloc/free calls:

dlls/ntdll/server.c:if (!(tmp_dir = malloc( p + 1 -
config_dir ))) fatal_error( "out of memory\n" );
dlls/msvcrt/heap.c: *  malloc (MSVCRT.@)
dlls/msvcrt/tests/printf.c:str = malloc(1024);
dlls/msvcrt/tests/printf.c:str = malloc(1024);
dlls/msvcrt/tests/heap.c:   mem1 = malloc(size1);
dlls/msvcrt/tests/heap.c:   mem1 = malloc(size1);
dlls/msvcrt/tests/heap.c:mem = malloc(0);
dlls/msvcrt/tests/file.c:buffer = malloc( len * sizeof(WCHAR) );
dlls/msvcrt/tests/cpp.c: * or at program exit malloc() checking if
these methods haven't been

As far as I understand those files test the core functionality and
should use malloc. If this is so, then malloc/free replacement for
dlls is complete.

The source code could be compiled without problems after applying the patch.

I'm behind a firewall and couldn't clone the repository even via http
(for some other projects it is functioning). That's why my patch was
made with quilt.

See the GitWine page in the Wiki on how to create git exports.

James McKenzie





[PATCH] JanitorialProjects/ReplaceMalloc: remove malloc and free from dlls folder

2010-12-30 Thread Yegor Yefremov
Hello,

it's my first contribution to wine, so I wanted to start with some
simple task. After fixing the files mentioned in the attached patch,
following files in dlls folder still contain malloc/free calls:

dlls/ntdll/server.c:if (!(tmp_dir = malloc( p + 1 -
config_dir ))) fatal_error( "out of memory\n" );
dlls/msvcrt/heap.c: *  malloc (MSVCRT.@)
dlls/msvcrt/tests/printf.c:str = malloc(1024);
dlls/msvcrt/tests/printf.c:str = malloc(1024);
dlls/msvcrt/tests/heap.c:   mem1 = malloc(size1);
dlls/msvcrt/tests/heap.c:   mem1 = malloc(size1);
dlls/msvcrt/tests/heap.c:mem = malloc(0);
dlls/msvcrt/tests/file.c:buffer = malloc( len * sizeof(WCHAR) );
dlls/msvcrt/tests/cpp.c: * or at program exit malloc() checking if
these methods haven't been

As far as I understand those files test the core functionality and
should use malloc. If this is so, then malloc/free replacement for
dlls is complete.

The source code could be compiled without problems after applying the patch.

I'm behind a firewall and couldn't clone the repository even via http
(for some other projects it is functioning). That's why my patch was
made with quilt.

Best regards,
Yegor


malloc-replace.patch
Description: Binary data