[poppler] [PATCH] cairo: drawChar->drawString

Jeff Muizelaar jrmuizel at nit.ca
Fri Mar 4 12:21:58 PST 2005


Forgot to cc the list

On Fri, Mar 04, 2005 at 08:22:54PM +0100, Albert Astals Cid wrote:
> 
> "Variable-length automatic arrays are allowed in ISO C99, and as an extension 
> GCC accepts them in C89 mode and in C++."
> http://gcc.gnu.org/onlinedocs/gcc-3.4.3/gcc/Variable-Length.html
> 
> So i think you should fine another aproach so that we stay compatible with the 
> standards (that sentence means variable size arrays are not in C++ standard)
> 
One thing that could be done is to go something like:

#ifdef GNUCC
#define limit(a,b) a
#else
#define limit(a,b) b
#endif

and then do:
cairo_glyph_t glyphs[limit(len, 32768)];

-Jeff


More information about the poppler mailing list