|
From: | Paolo Bonzini |
Subject: | Re: [PATCH] popen-safer: test O_CLOEXEC at run-time. |
Date: | Fri, 21 Aug 2009 14:03:48 +0200 |
User-agent: | Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.1) Gecko/20090814 Fedora/3.0-2.6.b3.fc11 Lightning/1.0pre Thunderbird/3.0b3 |
+#ifdef O_CLOEXEC + /* 0 = unknown, 1 = yes, -1 = no. */ + static bool have_cloexec;This has to be an int, not a bool, per the documented semantics you gave it.
Right.
+ if (have_cloexec>= 0) + { + fd = open (name, flags | O_CLOEXEC);^ Not sure how that 8-bit character got there.
Since it was a git-send-email message, I'm not sure too... Paolo
[Prev in Thread] | Current Thread | [Next in Thread] |