nmh-workers
[Top] [All Lists]

Re: [Nmh-workers] nmh readline support

2011-12-24 09:54:40
Steve wrote:

 > Date: Tue, 21 Dec 2010 09:38:45 CST
 > To: Peter Maydell <pmaydell(_at_)chiark(_dot_)greenend(_dot_)org(_dot_)uk>,
 >  nmh-workers(_at_)nongnu(_dot_)org
 > From: rader(_at_)hep(_dot_)wisc(_dot_)edu
 > Subject: Re: [Nmh-workers] GNU readline whatnowproc (was tab
 > completion)
 >
 > I like everything you've said.  I'll send along a better patch for
 > consideration soon.

364 days later... here's a patch that I think correctly adds readline
support to whatnowproc... some advice please...

(1) Is it really safe to wedge this in everywhere like Peter Maydell
asked for back on 12/21/2010??

Peter noted that readline is GPL, and there are some "BSD-ish"
licensed equivalents available.  nmh currently doesn't rely on
any GPL code, as far as I can tell, and I think we should maintain
that.

(2) What's the nmh native way to do...
  char *dupstr (char *s) {
    char *r;
    r = xmalloc (strlen (s) + 1);
    strcpy (r, s);
    return (r);
  }
?

strdup(), and it's used other places in nmh.

(3) I'm not exactly sure why there are parens in some of the option
syntax listings like "(de)tach [-n]".  I suspect they're indicating
"de" is acceptable (in a non-readline-world), and thus this code (in
a readlin eworld) should remove the parens?

Right.

David

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers

<Prev in Thread] Current Thread [Next in Thread>