[poppler] qt4/src/poppler-qiodeviceoutstream.cc: open_memstream is non-portable

Kristian Høgsberg krh at bitplanet.net
Mon Jan 28 14:53:26 PST 2008

On Jan 28, 2008 5:20 PM, Albert Astals Cid <aacid at kde.org> wrote:
> A Dilluns 28 Gener 2008, Jonathan Kew va escriure:
> > The document saving code in the Qt4 wrapper uses open_memstream(),
> > which is not available on all platforms. I would recommend using
> > vasprintf() instead, which I suspect is more widely supported, but
> > this is also a GNU extension and may not be available everywhere. So
> > a fallback approach using vsnprintf() is also needed.
> >
> > Proposed changes below....
> I'll let Pino comment on that, but he is travelling so it'll take a while.

I'll weigh in though and say that using open_memstream() isn't
acceptable, it's very GNU Libc specific.  Also, the suggested patch
has the same problems as the strndup() patch.  I'm sure there is a
helper function  in Qt to create a dynamically allocated string from a
printf-style string, that would be the way to go.


More information about the poppler mailing list