[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Nmh-workers] More than one parameters in .mh_profile

From: Ken Hornstein
Subject: Re: [Nmh-workers] More than one parameters in .mh_profile
Date: Mon, 28 May 2012 23:34:19 -0400

>>Sure, it COULD do that.  Sounds like you're volunteering to write
>>the code; great! :-)
>I hack perl, not C. I did quickly grep the perl code base for it though,
>but being on a tablet at the moment could not dive too deeply.
>nmh is non-GNU, but perl is dual-licensed under the Artistic License.

I take you haven't LOOKED at the perl source code lately?  Talk about
seeing how the sausage is being made; I will never complain about our
mess of ifdefs again.

But I'll save you the trouble.  Inside of Perl_do_exec3() the key lines
sems to be:

    for (s = cmd; *s; s++) {
        if (*s != ' ' && !isALPHA(*s) &&
            strchr("$&*(){}[]'\";\\|?<>~`\n",*s)) {

Seems like that's a pretty good list; if we see one of those characters,
it gets sent to /bin/sh -c.  Otherwise we split and do it ourselves.  Would
that make people happy?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]