nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit 6c1674429257859d469d5c5aa82acdc7b35f4e70
parent 86a64b1bb51e58e811f24c5afc65b9ca9aab8f1b
Author: Benno Schulenberg <bensberg@justemail.net>
Date:   Mon, 23 May 2016 16:24:12 +0200

files: avoid a warning about not being able to write a lockfile

Instead be more specific and say that the directory is not writable.

Diffstat:
Msrc/files.c | 2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/files.c b/src/files.c @@ -51,6 +51,8 @@ bool has_valid_path(const char *filename) statusline(ALERT, _("Path '%s' is not a directory"), parentdir); else if (access(parentdir, X_OK) == -1) statusline(ALERT, _("Path '%s' is not accessible"), parentdir); + else if (ISSET(LOCKING) && access(parentdir, W_OK) == -1) + statusline(MILD, _("Directory '%s' is not writable"), parentdir); else validity = TRUE;