projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Merge branch 'topic/intel8x0' into for-linus
[firefly-linux-kernel-4.4.55.git]
/
include
/
linux
/
namei.h
diff --git
a/include/linux/namei.h
b/include/linux/namei.h
index 99eb80306dc5bba4fab74b9a1693222209d619ea..fc2e035798776a5f65a813a4c1cf55778d2d700e 100644
(file)
--- a/
include/linux/namei.h
+++ b/
include/linux/namei.h
@@
-94,4
+94,9
@@
static inline char *nd_get_link(struct nameidata *nd)
return nd->saved_names[nd->depth];
}
+static inline void nd_terminate_link(void *name, size_t len, size_t maxlen)
+{
+ ((char *) name)[min(len, maxlen)] = '\0';
+}
+
#endif /* _LINUX_NAMEI_H */