[Pyrex] Re: [newbie] 3 errors need help
Toby
tobia.conforto at linux.it
Tue Dec 20 17:15:00 CET 2005
Why is your variable called __Session__ in one place and ___Session___
(with three underscores) in another?
Try also &(self.__Session__) instead of &self.__Session__
Second issue: you can't convert a Python string into a C String simply
by doing <unsigned char *>self.Key you need to allocate space for the
C string and copy it over, like:
cdef unsigned char c_key[MAX_SOMETHING]
c_key = self.Key
Take care to allocate space in a way that's compatible with the expected
longevity of the C string.
I'm a newbie as well, so this could all be wrong :)
Toby
More information about the Pyrex
mailing list