in reply to Returning undef from XS code

perldoc perlxstut
perldoc perlxs