aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/undo.c
diff options
context:
space:
mode:
authorFelipe Oliveira Carvalho <felipekde@gmail.com>2014-05-08 21:34:46 -0300
committerFelipe Oliveira Carvalho <felipekde@gmail.com>2014-05-19 14:50:23 -0300
commita80d7e86c1f088c5b68d8e8929cc72a0d9680f76 (patch)
treecc9cc71ee35fe966779cf6764bd5faabd1186df3 /src/nvim/undo.c
parentb63d2626ed9e3e38a485b9990a8e65ba59d6906a (diff)
downloadrneovim-a80d7e86c1f088c5b68d8e8929cc72a0d9680f76.tar.gz
rneovim-a80d7e86c1f088c5b68d8e8929cc72a0d9680f76.tar.bz2
rneovim-a80d7e86c1f088c5b68d8e8929cc72a0d9680f76.zip
Remove NULL/non-NULL tests after calls to vim_str(n)save()
Diffstat (limited to 'src/nvim/undo.c')
-rw-r--r--src/nvim/undo.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/nvim/undo.c b/src/nvim/undo.c
index 4d499cc28e..65ecebf65e 100644
--- a/src/nvim/undo.c
+++ b/src/nvim/undo.c
@@ -700,8 +700,6 @@ char_u *u_get_undo_file_name(char_u *buf_ffname, int reading)
/* Use same directory as the ffname,
* "dir/name" -> "dir/.name.un~" */
undo_file_name = vim_strnsave(ffname, (int)(STRLEN(ffname) + 5));
- if (undo_file_name == NULL)
- break;
p = path_tail(undo_file_name);
memmove(p + 1, p, STRLEN(p) + 1);
*p = '.';
@@ -711,8 +709,6 @@ char_u *u_get_undo_file_name(char_u *buf_ffname, int reading)
if (os_isdir(dir_name)) {
if (munged_name == NULL) {
munged_name = vim_strsave(ffname);
- if (munged_name == NULL)
- return NULL;
for (p = munged_name; *p != NUL; mb_ptr_adv(p))
if (vim_ispathsep(*p))
*p = '%';