diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-08-21 17:07:45 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-08-21 17:07:45 +0200 |
commit | fd6100b2aa6178b88cfadcdbc494966bf79a5488 (patch) | |
tree | 84eaf9a9ce4115b073c81c184d8d4694bfe0a1e5 /src/undo.c | |
parent | 0f6b4f06dece71487a6d8546c50de775d9c8c287 (diff) | |
download | vim-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.c | 9 |
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); + } } /* |