mirror of
https://github.com/neovim/neovim.git
synced 2025-10-15 14:26:07 +00:00
Replace vim_strncpy calls: if_cscope.c
This commit is contained in:

committed by
Justin M. Keyes

parent
e554ea2036
commit
4e81698988
@@ -295,7 +295,7 @@ int cs_fgets(char_u *buf, int size)
|
||||
|
||||
if ((p = cs_manage_matches(NULL, NULL, -1, Get)) == NULL)
|
||||
return TRUE;
|
||||
vim_strncpy(buf, (char_u *)p, size - 1);
|
||||
STRLCPY(buf, p, size);
|
||||
|
||||
return FALSE;
|
||||
} /* cs_fgets */
|
||||
@@ -2043,9 +2043,9 @@ static char *cs_resolve_file(int i, char *name)
|
||||
/* If 'cscoperelative' is set and ppath is not set, use cscope.out
|
||||
* path in path resolution. */
|
||||
csdir = xmalloc(MAXPATHL);
|
||||
vim_strncpy(csdir, (char_u *)csinfo[i].fname,
|
||||
STRLCPY(csdir, csinfo[i].fname,
|
||||
path_tail((char_u *)csinfo[i].fname)
|
||||
- (char_u *)csinfo[i].fname);
|
||||
- (char_u *)csinfo[i].fname + 1);
|
||||
len += STRLEN(csdir);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user