Merged revisions 309033-309034 via svnmerge from

https://origsvn.digium.com/svn/asterisk/branches/1.6.2

........
  r309033 | tilghman | 2011-02-28 04:43:12 -0600 (Mon, 28 Feb 2011) | 4 lines
  
  A later version of flex already includes the fwrite workaround code, which if used twice causes a compilation error.
  
  Detect whether Flex will compile without the workaround; if so, suppress our workaround code.
........
  r309034 | tilghman | 2011-02-28 05:07:52 -0600 (Mon, 28 Feb 2011) | 2 lines
  
  Clarify meaning, removing double negative (stupid!)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@309035 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Tilghman Lesher
2011-02-28 11:10:28 +00:00
parent f14ba8fa19
commit 1b78442e0d
5 changed files with 654 additions and 460 deletions

View File

@@ -65,10 +65,12 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
#include "asterisk/channel.h"
#endif
/*!\note The latest Flex uses fwrite without checking its return value, which
#ifdef NEED_FLEX_FWRITE_WORKAROUND
/*!\note Some versions of Flex use fwrite without checking its return value, which
* is a warning on some compilers. Therefore, we use this workaround, to trick
* the compiler into suppressing this warning. */
#define fwrite(a,b,c,d) do { int __res = fwrite(a,b,c,d); (__res); } while (0)
#endif
enum valtype {
AST_EXPR_number, AST_EXPR_numeric_string, AST_EXPR_string