diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/udev/collect/collect.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/udev/collect/collect.c b/src/udev/collect/collect.c index feae4bb6ba..3c46e40de1 100644 --- a/src/udev/collect/collect.c +++ b/src/udev/collect/collect.c @@ -93,7 +93,7 @@ static int prepare(char *dir, char *filename) if (stat(dir, &statbuf) < 0) mkdir(dir, 0700); - sprintf(buf, "%s/%s", dir, filename); + snprintf(buf, sizeof(buf), "%s/%s", dir, filename); fd = open(buf,O_RDWR|O_CREAT, S_IRUSR|S_IWUSR); if (fd < 0) |