Hi,
If I define in C a char[X] and set it to be X characters (without the
\0 at the end) in the script language (Perl for instance), SWIG will
fill the char buffer without the null terminating character and
without any error.
It is a bit strange to me, because if I look at the generated code
(SWIG_AsCharArray), it always return a null terminating string if
there is enough space in buffer but let a non null terminating string
in the special case where no space is left.
I would have prefer that it returns an error if no space is left
rather than returning a non null terminated character.
How could I emulate such a behaviour ?
SWIG Version 1.3.31
Regards,
--
Pierre Mallard
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference_______________________________________________
Swig-user mailing list
Swig-user@...
https://lists.sourceforge.net/lists/listinfo/swig-user