This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 3/6] Reinstantiate fd range check if and only if defined _STRICT_FD_SIZE_CHECK=1


On 04/02/2013 09:23 PM, KOSAKI Motohiro wrote:
On Tue, Apr 2, 2013 at 4:53 AM, Florian Weimer <fweimer@redhat.com> wrote:
On 03/29/2013 04:17 PM, kosaki.motohiro@gmail.com wrote:

   /* Define some inlines helping to catch common problems.  */
-#if __USE_FORTIFY_LEVEL > 0 && defined __GNUC__
+#if __USE_FORTIFY_LEVEL > 0 && defined __GNUC__ && _STRICT_FD_SIZE_CHECK
0
   # include <bits/select2.h>
   #endif


I think this is backwards.  The default with _FORTIFY_SOURCE should be to
check, but having a way to disable the checks if needed might be helpful in
some cases.  (Porting to poll/epoll/glib event loop is almost always
preferable, though.)

That breaks several applications and we can't take that.

How so? _FORTIFY_SOURCE is not enabled by default. If you switch it on, there are other (valid) uses which break.

--
Florian Weimer / Red Hat Product Security Team


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]