Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
LU-11233 utils: fix build warnings for gcc8
[fs/lustre-release.git]
/
lustre
/
utils
/
mount_lustre.c
diff --git
a/lustre/utils/mount_lustre.c
b/lustre/utils/mount_lustre.c
index
1acd635
..
beb42a8
100644
(file)
--- a/
lustre/utils/mount_lustre.c
+++ b/
lustre/utils/mount_lustre.c
@@
-348,7
+348,8
@@
int parse_options(struct mount_opts *mop, char *orig_options,
free(options);
return EINVAL;
}
- strncpy(mop->mo_skpath, val + 1, strlen(val + 1));
+ strncpy(mop->mo_skpath, val + 1,
+ sizeof(mop->mo_skpath) - 1);
#endif
} else if (parse_one_option(opt, flagp) == 0) {
/* pass this on as an option */