Stas Bekman wrote:
[...]

+    eval_pv(apr_psprintf(p, "{ local $0 = q[%s]; %s }",
+                         directive->filename, arg), FALSE);

I've figured that if the above works, why can't we do the same in C API. So I've digged in and learned that save_item doesn't handle magic. So here is a short and sweet solution that works:


    {
        GV *gv = gv_fetchpv("0", TRUE, SVt_PV);
        ENTER;
        save_scalar(gv);
        sv_setpv_mg(GvSV(gv), directive->filename);
        eval_pv(arg, FALSE);
        LEAVE;
    }

now committed.

__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to