in reply to Re: Odd behavior with a "vertical tab" character
in thread Odd behavior with a "vertical tab" character

I'm not calling "Raw" directly in my code, but here is the relevant structure from Pilot.xs itself:
#define PackRaw\ {\ HV * h;\ if (SvRV(data) &&\ (SvTYPE(h=(HV*)SvRV(data))==SVt_PVHV)) {\ int count;\ PUSHMARK(sp);\ XPUSHs(data);\ PUTBACK;\ count = perl_call_method("Raw", G_SCALAR);\ SPAGAIN;\ if (count != 1) {\ SV ** s = hv_fetch(h, "raw", 3, 0);\ if (s)\ data = *s;\ } else {\ data = POPs;\ PUTBACK;\ }\ }\ }

Replies are listed 'Best First'.
Re: Re: Odd behavior with a "vertical tab" character
by Courage (Parson) on Nov 05, 2002 at 20:30 UTC
    While I am not ready to point you to an exact place of an error (and do not expect me to, as we still have not enough information), but several notes I will do in my humble tries to step forward.
    1. "perl_call_method" call is 100% not portable between different installations of perl, you should use "call_method" and let "perl.h" to correctly prefix it. You're in danger of facing hard-to-fix errors if you're just following requests of your linker.
    2. Is your extra PUTBACK; at the very end of "PackRaw" macro is intentional?
    3. (most important point) As logic says, your code should not call "Raw" method at all, because your macro first checks for "SvRV" and will not suffice for sure. Is there any other place where your "Raw" method is called? Can you output a call trace?

    Courage, the Cowardly Dog