Skip to content

Commit

Permalink
PSTRESS-42 Unable to compile pstress with gcc 9
Browse files Browse the repository at this point in the history
Details: benhoyt/inih#104

The fix has been included in pstress
  • Loading branch information
mohitj1988 committed Jun 8, 2020
1 parent 415b5ce commit a4fbeb3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/third_party/inih++/lib/ini.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ static char* find_char_or_comment(const char* s, char c) {

/* Version of strncpy that ensures dest (size bytes) is null-terminated. */
static char* strncpy0(char* dest, const char* src, size_t size) {
strncpy(dest, src, size);
memcpy(dest, src, size);
dest[size - 1] = '\0';
return dest;
}
Expand Down

0 comments on commit a4fbeb3

Please sign in to comment.