Bugzilla – Bug 417
Please don't change file suffix for sudoedit
Last modified: 2010-08-02 15:01:03 MDT
Editors like Emacs often choose the editing mode for a file based on its suffix, and sudoedit frustrates this by adding some random characters to the file name. Could it please add the random characters elsewhere? Adding them to just before the suffix would be nice. I see this needs a different function from mkstemp to achieve. mkstemps is available on many systems (including BSDs and glibc since 2.11), and fits the bill. Would you consider a patch that uses mkstemps where available and the current code (using mkstemp) otherwise?
I'll look at doing this for sudo 1.7.4
Thanks, that would be brilliant!
This turns out to be fairly simple. Give this a try: ftp://ftp.sudo.ws/pub/millert/sudo/sudo-1.7.3-mkstemps.tar.gz
That's great, it seems to work fine. Thanks very much!
Closing, sudo 1.7.4 is out now.