[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Question regarding the XML parser binding in PIL
- From: "Sam Roberts" <vieuxtech@...>
- Date: Fri, 21 Nov 2008 13:09:23 -0800
On Fri, Nov 21, 2008 at 9:36 AM, Florian Weimer <firstname.lastname@example.org> wrote:
> Let's assume that expat's XML_Parse function is called directly. Then
> the L in the userdata object is not updated and may have become
> invalid (if it's not from the master state, for example).
> It might sound a bit silly for expat, but for other cases (like
> user-defined functions in SQLite) it's not that far-fetched, IMHO.
Its totally unclear to me what you are talking about.
This function exists so expat can be bound to lua and used in lua (or
C code called from lua, same thing), right?
All running lua code exists within the context of a lua state. If
there is no valid lua state.... its not lua. If its not lua, why would
you be calling expat directly on a lua user data? And how did you get
Maybe you should just try to do whatever it is you are trying to do,
and see if it works?
If it doesn't you can explain what the trouble is, and someone will
surely help you.
Btw, if you think this is an issue for something like user-defined
functions in sqlite, maybe try reading the sqlite bindings, the docs
indicate they do user-defined functions: