help-smalltalk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-smalltalk] Re: cairo library wrapper


From: Paolo Bonzini
Subject: Re: [Help-smalltalk] Re: cairo library wrapper
Date: Wed, 22 Nov 2006 09:12:11 +0100
User-agent: Thunderbird 1.5.0.8 (Macintosh/20061025)

Stephen Compall wrote:
On Tue, 2006-11-21 at 20:13 -0800, Brad Watson wrote:
how to implement a work around for it's requirement for accessing files via
a FILE * pointer rather than a file descriptor which is what gst provides. Ideas anyone ?

See (glibc)Custom Streams::, or
http://www.gnu.org/software/libc/manual/html_node/Custom-Streams.html

You could use an fdopen but you have to be careful because fclosing the FILE * pointer will close the original buffer, and not closing it will leak the memory for the buffers. I'm curious whether a setvbuf to disable buffering, plus freeing the FILE * is decently portable (at least in practice).

Paolo




reply via email to

[Prev in Thread] Current Thread [Next in Thread]