Re: [PATCH 04/15] Set _O_BINARY as default fmode for both MinGW and MSVC
- From
Marius Storm-Olsen <mstormo@gmail.com>
- Date
- Sep 17, 2009, 07:27 UTC
- Message-ID
- <4AB1E4C5.80102@gmail.com>
- In-Reply-To
- <4AB1E118.70504@viscovery.net>
Johannes Sixt said the following on 17.09.2009 09:11:
Show 23 quoted lines
> Alexey Borzenkov schrieb:
>> Searching which executables set _fmode and which don't I found the
>> culprit. test-genrandom.c didn't include git-compat-util.h, so mingw.h
>> was never included. This caused different random data to be generated,
>> and as it seems more importantly, of different sizes. Can be fixed
>> with this patch:
>>
>> diff --git a/test-genrandom.c b/test-genrandom.c
>> index 8ad276d..b3c28d9 100644
>> --- a/test-genrandom.c
>> +++ b/test-genrandom.c
>> @@ -4,8 +4,7 @@
>> * Copyright (C) 2007 by Nicolas Pitre, licensed under the GPL version 2.
>> */
>>
>> -#include <stdio.h>
>> -#include <stdlib.h>
>> +#include "git-compat-util.h"
>>
>> int main(int argc, char *argv[])
>> {
>
> Thanks for digging this out. With this change, the t5302 passes again.Yup, are you ok with squashing this hunk into the patch then?
-- .marius