From a73ab0446ac1e2d59062d8ce544e33efcf68310a Mon Sep 17 00:00:00 2001 From: Leonid Krivoshein Date: Sun, 22 Apr 2018 15:31:04 +0300 Subject: [PATCH] common.c: more strict address ariphmetic. --- common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common.c b/common.c index c9f96f8..74e4f04 100644 --- a/common.c +++ b/common.c @@ -11,7 +11,7 @@ int mkdir_dev(const char * name) { char pathname[PATH_MAX + 1] = "/dev/"; - strcpy(pathname + 5, name); + strcpy(&pathname[5], name); return (mkdir(pathname, 0755) == 0 || errno == EEXIST) ? 0 : -1; }