diff options
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -189,7 +189,8 @@ static void parse_config(GKeyFile *config) g_clear_error(&err); } else { debug("deviceid=%s", str); - strncpy(main_opts.deviceid, str, sizeof(main_opts.deviceid)); + strncpy(main_opts.deviceid, str, + sizeof(main_opts.deviceid) - 1); g_free(str); } |