projects
/
project
/
procd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
system: fix localtime value in ubus info method output
[project/procd.git]
/
plug
/
udevtrigger.c
diff --git
a/plug/udevtrigger.c
b/plug/udevtrigger.c
index
5013189
..
3eba19a
100644
(file)
--- a/
plug/udevtrigger.c
+++ b/
plug/udevtrigger.c
@@
-114,7
+114,7
@@
static int sysfs_resolve_link(char *devpath, size_t size)
strlcpy(link_path, "/sys", sizeof(link_path));
strlcat(link_path, devpath, sizeof(link_path));
strlcpy(link_path, "/sys", sizeof(link_path));
strlcat(link_path, devpath, sizeof(link_path));
- len = readlink(link_path, link_target, sizeof(link_target));
+ len = readlink(link_path, link_target, sizeof(link_target)
- 1
);
if (len <= 0)
return -1;
link_target[len] = '\0';
if (len <= 0)
return -1;
link_target[len] = '\0';