]> Sergey Matveev's repositories - nnn.git/commitdiff
Copy the correct length
authorArun Prakash Jana <engineerarun@gmail.com>
Sat, 27 Jun 2020 19:22:24 +0000 (00:52 +0530)
committerArun Prakash Jana <engineerarun@gmail.com>
Sat, 27 Jun 2020 19:22:24 +0000 (00:52 +0530)
README.md
src/nnn.c

index e1492d1ca3d366709374806a8e2be8e44aecbf14..d004301e0dfb0de96a27eacd049ce8c0b860fa5e 100644 (file)
--- a/README.md
+++ b/README.md
@@ -30,7 +30,7 @@ It runs smoothly on the Pi, [Termux](https://www.youtube.com/watch?v=AbaauM7gUJw
 
 - Instantly load, sort, filter thousands of files
 - Type to navigate with automatic dir selection
-- Never lose context - start where you quit `nnn`
+- Never lose context - start where you quit
 - find/fd/grep/ripgrep/fzf from `nnn` and list in `nnn`
 - Mount any cloud storage service in a few keypresses
 - Select files from anywhere (not just a single dir)
index 72b01836a42586f0de307658c75116c58c297e34..4443022c7471a5e82af847a6154d8bc34bf85a3d 100644 (file)
--- a/src/nnn.c
+++ b/src/nnn.c
@@ -6433,7 +6433,7 @@ nochange:
                                         */
                                        if (strcmp(path, plgpath) == 0) {
                                                xstrsncpy(path, rundir, PATH_MAX);
-                                               xstrsncpy(lastname, runfile, NAME_MAX);
+                                               xstrsncpy(lastname, runfile, NAME_MAX + 1);
                                                rundir[0] = runfile[0] = '\0';
                                                setdirwatch();
                                                goto begin;