Skip to content

Commit

Permalink
Fix an issue found by Coverity Scan
Browse files Browse the repository at this point in the history
  • Loading branch information
ysyrota authored and AaronAtDuo committed Oct 23, 2024
1 parent fcd5d5a commit 8d65a82
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/util.c
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ duo_common_ini_handler(struct duo_config *cfg, const char *section,
size_t j = 0;
int inEscape = 0;
char *currWord;
if ((currWord = malloc(len)) == NULL) {
if ((currWord = malloc(len + 1)) == NULL) {
fprintf(stderr, "Out of memory parsing groups\n");
return (0);
}
Expand Down

0 comments on commit 8d65a82

Please sign in to comment.