diff options
author | Mark Bainter <mbainter+github@gmail.com> | 2015-05-04 12:41:10 -0500 |
---|---|---|
committer | Mark Bainter <mbainter+github@gmail.com> | 2015-05-06 21:34:19 -0500 |
commit | 4ccf2740c88a6113ec5c512dff0afed993a0727a (patch) | |
tree | db81f34e448f0c9f85d276aceb3b5a19af99aa89 | |
parent | a2273164b6d45f4cfe3fc6bb828aaa793904fa55 (diff) | |
download | rneovim-4ccf2740c88a6113ec5c512dff0afed993a0727a.tar.gz rneovim-4ccf2740c88a6113ec5c512dff0afed993a0727a.tar.bz2 rneovim-4ccf2740c88a6113ec5c512dff0afed993a0727a.zip |
Make fname const in path_get_absolute_path()
Also a minor change to remove an unneeded cast
-rw-r--r-- | src/nvim/path.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/path.c b/src/nvim/path.c index 9ceccb8ebd..cefa2dcbf8 100644 --- a/src/nvim/path.c +++ b/src/nvim/path.c @@ -2052,7 +2052,7 @@ int append_path(char *path, const char *to_append, int max_len) /// @param len Length of `buf`. /// @param force Also expand when `fname` is already absolute. /// @return `FAIL` for failure, `OK` for success. -static int path_get_absolute_path(char_u *fname, char_u *buf, int len, int force) +static int path_get_absolute_path(const char_u *fname, char_u *buf, int len, int force) { char_u *p; *buf = NUL; @@ -2075,7 +2075,7 @@ static int path_get_absolute_path(char_u *fname, char_u *buf, int len, int force return FAIL; } } - return append_path((char *) buf, (char *) end_of_path, len); + return append_path((char *)buf, end_of_path, len); } /// Check if the given file is absolute. |