From: Collin Funk Date: Sat, 7 Jun 2025 23:20:27 +0000 (-0700) Subject: posix: Add nonnull attribute to glob_pattern_p. X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c3b9abaf33082c89ff385b378e083aad1255f508;p=thirdparty%2Fglibc.git posix: Add nonnull attribute to glob_pattern_p. * posix/glob.h (glob_pattern_p): Add __nonnull ((1)) since this function expects a string and does not check for NULL. Signed-off-by: Collin Funk Reviewed-by: Adhemerval Zanella --- diff --git a/posix/glob.h b/posix/glob.h index 6bb0c6f584..e5442dd9c1 100644 --- a/posix/glob.h +++ b/posix/glob.h @@ -195,7 +195,8 @@ extern void globfree64 (glob64_t *__pglob) __THROW; This function is not part of the interface specified by POSIX.2 but several programs want to use it. */ -extern int glob_pattern_p (const char *__pattern, int __quote) __THROW; +extern int glob_pattern_p (const char *__pattern, int __quote) __THROW + __nonnull ((1)); #endif __END_DECLS