From cefd8bb36d307a671fbbe5358d94c97910edf7c6 Mon Sep 17 00:00:00 2001 From: Darren Tucker Date: Mon, 15 May 2006 17:17:29 +1000 Subject: - (dtucker) [defines.h] Find a value for IOV_MAX or use a conservative default. Patch originally from tim@, ok djm --- defines.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'defines.h') diff --git a/defines.h b/defines.h index 9ecf18d5a..f2fdd3cad 100644 --- a/defines.h +++ b/defines.h @@ -25,7 +25,7 @@ #ifndef _DEFINES_H #define _DEFINES_H -/* $Id: defines.h,v 1.131 2006/03/15 02:02:28 djm Exp $ */ +/* $Id: defines.h,v 1.132 2006/05/15 07:17:30 dtucker Exp $ */ /* Constants */ @@ -731,6 +731,16 @@ struct winsize { # undef HAVE_MMAP #endif +#ifndef IOV_MAX +# if defined(_XOPEN_IOV_MAX) +# define IOV_MAX _XOPEN_IOV_MAX +# elif defined(DEF_IOV_MAX) +# define IOV_MAX DEF_IOV_MAX +# else +# define IOV_MAX 16 +# endif +#endif + /* some system headers on HP-UX define YES/NO */ #ifdef YES # undef YES -- cgit v1.2.3