summaryrefslogtreecommitdiff
path: root/src/undo.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2018-08-21 17:07:45 +0200
committerBram Moolenaar <Bram@vim.org>2018-08-21 17:07:45 +0200
commitfd6100b2aa6178b88cfadcdbc494966bf79a5488 (patch)
tree84eaf9a9ce4115b073c81c184d8d4694bfe0a1e5 /src/undo.c
parent0f6b4f06dece71487a6d8546c50de775d9c8c287 (diff)
downloadvim-git-fd6100b2aa6178b88cfadcdbc494966bf79a5488.tar.gz
patch 8.1.0308: a quick undo shows "1 seconds ago"v8.1.0308
Problem: A quick undo shows "1 seconds ago". (Tony Mechelynck) Solution: Add singular/plural message.
Diffstat (limited to 'src/undo.c')
-rw-r--r--src/undo.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/undo.c b/src/undo.c
index 040ec5480..ebf18da49 100644
--- a/src/undo.c
+++ b/src/undo.c
@@ -3124,8 +3124,13 @@ u_add_time(char_u *buf, size_t buflen, time_t tt)
}
else
#endif
- vim_snprintf((char *)buf, buflen, _("%ld seconds ago"),
- (long)(vim_time() - tt));
+ {
+ long seconds = (long)(vim_time() - tt);
+
+ vim_snprintf((char *)buf, buflen,
+ NGETTEXT("%ld second ago", "%ld seconds ago", seconds),
+ seconds);
+ }
}
/*