nano-devel
[Top][All Lists]
Advanced

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

[Nano-devel] .nano_history loading


From: David Benbennick
Subject: [Nano-devel] .nano_history loading
Date: Mon, 9 Aug 2004 17:59:56 -0400
User-agent: Mutt/1.4.1i

Here's a patch that revamps the history saving and loading functions.

Nano doesn't like long (>1023 characters) search strings saved in the 
history file.  Second, s (null characters) don't get handled correctly.  
Third, if getpwuid fails, Nano will crash (for example, if the user is 
removed from /etc/passwd while Nano is running).

The patch adds a function utils.c:homedir, which consolidates the code to 
figure out the home directory.  do_rcfile is changed to use the new 
function.

I use the GNU extension getline() in load_history().  This function would 
be useful in parse_rcfile() and in files.c too.  I suppose we'll have to 
think about providing a copy for people with non-gcc libraries.

Attachment: blah.patch
Description: Text document

Attachment: pgpBz_IvITQWG.pgp
Description: PGP signature


reply via email to

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