瀏覽代碼

When copying a single file sync cp file and cp buf

master
Arun Prakash Jana 6 年之前
父節點
當前提交
0169232d9c
沒有發現已知的金鑰在資料庫的簽署中 GPG 金鑰 ID: A75979F35C080412
共有 1 個檔案被更改,包括 8 行新增0 行删除
  1. +8
    -0
      src/nnn.c

+ 8
- 0
src/nnn.c 查看文件

@@ -2975,6 +2975,10 @@ nochange:
} else if (cfg.quote) {
g_buf[0] = '\'';
r = mkpath(path, dents[cur].name, g_buf + 1, PATH_MAX);
/* Keep the copy buf in sync */
copybufpos = 0;
appendfpath(g_buf + 1, r);

g_buf[r] = '\'';
g_buf[r + 1] = '\0';

@@ -2987,6 +2991,10 @@ nochange:
printmsg(g_buf + 1);
} else {
r = mkpath(path, dents[cur].name, newpath, PATH_MAX);
/* Keep the copy buf in sync */
copybufpos = 0;
appendfpath(newpath, r);

if (!copier)
writecp(newpath, r - 1); /* Truncate NULL from end */
else


Loading…
取消
儲存