On Mon, June 23, 2008 3:11 pm, Andreas Schulz wrote:
> On Sunday 22 June 2008, Stephen Warren wrote:
>> In the documentation for get_key_name, it may be worth mentioning
>> that valid index values start at 1
>
> anything wrong with "index starting at 1 for '1'st entry"?

Probably not, but it's sufficiently unusual for C (and many other
languages) that it's just worth mentioning.

> Well, concordance could do that as well, so what about:
>   char **get_keynames(uint8_t *data, uint32_t size);
>   void destroy_keynames(char **names);
> and be done with the XML data in one call?

That'd work too. I'll have to check whether it's easy to deal with
"char**" in the Python bindings; it should be...

> I started adding deallocators in libIRremotes, and will do so for
> libconcord. I'm not sure about the internals of python - will
> deallocators be of any use there, and when should they be called?

Absolutely useful. libconcord.py should simply expose the function call
as-is; never automatically call them (except in a situation where the
bindings actually copy the returned data into a Python type, rather than
returning a ctypes type referencing the memory, but we don't ever do that,
currently at least). The client app (e.g. congruity) should call them at
the same time a C application would; whenever it's done using the returned
data.


-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
concordance-devel mailing list
concordance-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/concordance-devel

Reply via email to