Re: [PATCH jk/pkt-line-cleanup] t5700-clone-reference: send trace to fd 2, not 3, to please Windows git

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 3/20/2013 10:33, schrieb Jeff King:
> On Wed, Mar 20, 2013 at 09:24:44AM +0100, Johannes Sixt wrote:
> 
>> From: Johannes Sixt <j6t@xxxxxxxx>
>>
>> Two tests use GIT_TRACE=3 to dump debugging information of git. On
>> Windows, however, bash is unable to set up file descriptor 3 correctly
>> for its child process, so that git reports "Bad file descriptor" on
>> every trace attempt. The 'git clone' test succeeds nevertheless because
>> an empty trace file remains, and there is only a check for the
>> absence of a particular line. But the 'git fetch' process ultimately
>> hangs (the dynamics that lead to this surprising result have not been
>> investigated).
>>
>> Since we do not otherwise use stderr in the test cases, divert the
>> trace dump to stderr.
> 
> I think that is OK, but I'm curious why this is a problem _now_, and not
> with the code prior to 97a83fa8. The old GIT_DEBUG_SEND_PACK was also
> just calling write() to descriptor 3.

Before this change, both affected commands completed and the trace file
was empty. Notice that in both test cases we only check for the absence of
certain lines, which is naturally true for an empty file, so that the
tests pass.

With the updated code, 'git fetch' hung, which is how I noticed the
problem. As I said, I didn't investigate where and why this happens.

>>  This fixes a regression introduced in 
> 
> ...in 97a83fa8, I assume.

Yes, correct. (Sorry, I got distracted while I looked up the commit.)

-- Hannes
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]