* [PATCH] posix: glob, glob64 should not be declared __THROW [BZ #27522]
@ 2021-03-05 12:56 Florian Weimer
2021-03-05 13:05 ` Adhemerval Zanella
0 siblings, 1 reply; 2+ messages in thread
From: Florian Weimer @ 2021-03-05 12:56 UTC (permalink / raw)
To: libc-alpha
These functions invoke callbacks with GLOB_ALTDIRFUNC, so they
are not leaf functions (as implied by _THROW). Use __THROWNL
and __REDIRECT_NTHNL to express this.
---
posix/glob.h | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/posix/glob.h b/posix/glob.h
index 71c6b84a8a..b5686600c7 100644
--- a/posix/glob.h
+++ b/posix/glob.h
@@ -145,15 +145,15 @@ typedef struct
#if !defined __USE_FILE_OFFSET64
extern int glob (const char *__restrict __pattern, int __flags,
int (*__errfunc) (const char *, int),
- glob_t *__restrict __pglob) __THROW;
+ glob_t *__restrict __pglob) __THROWNL;
/* Free storage allocated in PGLOB by a previous `glob' call. */
extern void globfree (glob_t *__pglob) __THROW;
#else
-extern int __REDIRECT_NTH (glob, (const char *__restrict __pattern,
- int __flags,
- int (*__errfunc) (const char *, int),
- glob_t *__restrict __pglob), glob64);
+extern int __REDIRECT_NTHNL (glob, (const char *__restrict __pattern,
+ int __flags,
+ int (*__errfunc) (const char *, int),
+ glob_t *__restrict __pglob), glob64);
extern void __REDIRECT_NTH (globfree, (glob_t *__pglob), globfree64);
#endif
@@ -161,7 +161,7 @@ extern void __REDIRECT_NTH (globfree, (glob_t *__pglob), globfree64);
#ifdef __USE_LARGEFILE64
extern int glob64 (const char *__restrict __pattern, int __flags,
int (*__errfunc) (const char *, int),
- glob64_t *__restrict __pglob) __THROW;
+ glob64_t *__restrict __pglob) __THROWNL;
extern void globfree64 (glob64_t *__pglob) __THROW;
#endif
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] posix: glob, glob64 should not be declared __THROW [BZ #27522]
2021-03-05 12:56 [PATCH] posix: glob, glob64 should not be declared __THROW [BZ #27522] Florian Weimer
@ 2021-03-05 13:05 ` Adhemerval Zanella
0 siblings, 0 replies; 2+ messages in thread
From: Adhemerval Zanella @ 2021-03-05 13:05 UTC (permalink / raw)
To: libc-alpha
On 05/03/2021 09:56, Florian Weimer via Libc-alpha wrote:
> These functions invoke callbacks with GLOB_ALTDIRFUNC, so they
> are not leaf functions (as implied by _THROW). Use __THROWNL
> and __REDIRECT_NTHNL to express this.
LGTM, thanks.
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
>
> ---
> posix/glob.h | 12 ++++++------
> 1 file changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/posix/glob.h b/posix/glob.h
> index 71c6b84a8a..b5686600c7 100644
> --- a/posix/glob.h
> +++ b/posix/glob.h
> @@ -145,15 +145,15 @@ typedef struct
> #if !defined __USE_FILE_OFFSET64
> extern int glob (const char *__restrict __pattern, int __flags,
> int (*__errfunc) (const char *, int),
> - glob_t *__restrict __pglob) __THROW;
> + glob_t *__restrict __pglob) __THROWNL;
>
> /* Free storage allocated in PGLOB by a previous `glob' call. */
> extern void globfree (glob_t *__pglob) __THROW;
> #else
> -extern int __REDIRECT_NTH (glob, (const char *__restrict __pattern,
> - int __flags,
> - int (*__errfunc) (const char *, int),
> - glob_t *__restrict __pglob), glob64);
> +extern int __REDIRECT_NTHNL (glob, (const char *__restrict __pattern,
> + int __flags,
> + int (*__errfunc) (const char *, int),
> + glob_t *__restrict __pglob), glob64);
>
> extern void __REDIRECT_NTH (globfree, (glob_t *__pglob), globfree64);
> #endif
> @@ -161,7 +161,7 @@ extern void __REDIRECT_NTH (globfree, (glob_t *__pglob), globfree64);
> #ifdef __USE_LARGEFILE64
> extern int glob64 (const char *__restrict __pattern, int __flags,
> int (*__errfunc) (const char *, int),
> - glob64_t *__restrict __pglob) __THROW;
> + glob64_t *__restrict __pglob) __THROWNL;
>
> extern void globfree64 (glob64_t *__pglob) __THROW;
> #endif
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-03-05 13:05 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-05 12:56 [PATCH] posix: glob, glob64 should not be declared __THROW [BZ #27522] Florian Weimer
2021-03-05 13:05 ` Adhemerval Zanella
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).