Skip to content
Snippets Groups Projects
Commit 30fe792a authored by schneider's avatar schneider
Browse files

fix(config): remote buffer overflow

parent ac1ce0a0
No related branches found
No related tags found
No related merge requests found
......@@ -295,7 +295,8 @@ static size_t read_config_offset(size_t seek_offset, char *buf, size_t buf_len)
return 0;
}
int nread = epic_file_read(fd, buf, buf_len);
// one byte less to accommodate the 0 termination
int nread = epic_file_read(fd, buf, buf_len - 1);
buf[nread] = '\0';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment