git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Sixt <j6t@kdbg.org>
To: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Cc: Junio C Hamano <gitster@pobox.com>,
	"GIT Mailing-list" <git@vger.kernel.org>,
	jrnieder@gmail.com, vmiklos@frugalware.org
Subject: Re: [PATCH 08/14] help.c: Fix detection of custom merge strategy on cygwin
Date: Tue, 14 Dec 2010 21:38:37 +0100	[thread overview]
Message-ID: <201012142138.37679.j6t@kdbg.org> (raw)
In-Reply-To: <4D07B786.2060602@ramsay1.demon.co.uk>

On Dienstag, 14. Dezember 2010, Ramsay Jones wrote:
> @@ -126,7 +126,10 @@ static int is_executable(const char *name)
>  	    !S_ISREG(st.st_mode))
>  		return 0;
>
> -#ifdef WIN32
> +#if defined(WIN32) || defined(__CYGWIN__)
> +#if defined(__CYGWIN__)
> +if ((st.st_mode & S_IXUSR) == 0)
> +#endif
>  {	/* cannot trust the executable bit, peek into the file instead */
>  	char buf[3] = { 0 };
>  	int n;

Do you gain a lot by this extra condition? Wouldn't

-#ifdef WIN32
+#if defined(WIN32) || defined(__CYGWIN__)

be sufficient?

-- Hannes

  parent reply	other threads:[~2010-12-14 20:39 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-14 18:29 [PATCH 08/14] help.c: Fix detection of custom merge strategy on cygwin Ramsay Jones
2010-12-14 20:07 ` Erik Faye-Lund
2010-12-16 21:03   ` Ramsay Jones
2010-12-16 23:06     ` Erik Faye-Lund
2010-12-14 20:38 ` Johannes Sixt [this message]
2010-12-16 21:12   ` Ramsay Jones
2010-12-17 21:46     ` Johannes Sixt
2010-12-18 20:41       ` Ramsay Jones

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201012142138.37679.j6t@kdbg.org \
    --to=j6t@kdbg.org \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=jrnieder@gmail.com \
    --cc=ramsay@ramsay1.demon.co.uk \
    --cc=vmiklos@frugalware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).