diff options
Diffstat (limited to 'xlators/features/changelog')
-rw-r--r-- | xlators/features/changelog/lib/src/gf-changelog.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/xlators/features/changelog/lib/src/gf-changelog.c b/xlators/features/changelog/lib/src/gf-changelog.c index 18eeac3e1a4..fb2d9037ffb 100644 --- a/xlators/features/changelog/lib/src/gf-changelog.c +++ b/xlators/features/changelog/lib/src/gf-changelog.c @@ -336,6 +336,11 @@ gf_changelog_next_change (char *bufptr, size_t maxlen) gf_changelog_t *gfc = NULL; char buffer[PATH_MAX] = {0,}; + if (maxlen > PATH_MAX) { + errno = ENAMETOOLONG; + goto out; + } + errno = EINVAL; this = THIS; |