public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc] Apply asm redirection in not-cancel before first use
@ 2022-11-01 13:08 Adhemerval Zanella
  0 siblings, 0 replies; only message in thread
From: Adhemerval Zanella @ 2022-11-01 13:08 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=d227fd53cbbc9ae7e5604da3669d04b6ccb53aa1

commit d227fd53cbbc9ae7e5604da3669d04b6ccb53aa1
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Mon Oct 24 16:12:15 2022 -0300

    Apply asm redirection in not-cancel before first use
    
    It is avoid a build failure on clang where it can not redeclare function
    attribute after its first use.
    
    Reviewed-by: Fangrui Song <maskray@google.com>

Diff:
---
 sysdeps/unix/sysv/linux/not-cancel.h | 30 +++++++++++++++---------------
 1 file changed, 15 insertions(+), 15 deletions(-)

diff --git a/sysdeps/unix/sysv/linux/not-cancel.h b/sysdeps/unix/sysv/linux/not-cancel.h
index 93615de681..d4f1e0fbde 100644
--- a/sysdeps/unix/sysv/linux/not-cancel.h
+++ b/sysdeps/unix/sysv/linux/not-cancel.h
@@ -52,6 +52,21 @@ __typeof (__write) __write_nocancel;
 /* Uncancelable close.  */
 __typeof (__close) __close_nocancel;
 
+/* Uncancelable fcntl.  */
+__typeof (__fcntl) __fcntl64_nocancel;
+
+#if IS_IN (libc) || IS_IN (rtld)
+hidden_proto (__open_nocancel)
+hidden_proto (__open64_nocancel)
+hidden_proto (__openat_nocancel)
+hidden_proto (__openat64_nocancel)
+hidden_proto (__read_nocancel)
+hidden_proto (__pread64_nocancel)
+hidden_proto (__write_nocancel)
+hidden_proto (__close_nocancel)
+hidden_proto (__fcntl64_nocancel)
+#endif
+
 /* Non cancellable close syscall that does not also set errno in case of
    failure.  */
 static inline void
@@ -80,19 +95,4 @@ __poll_infinity_nocancel (struct pollfd *fds, nfds_t nfds)
   return INLINE_SYSCALL_CALL (ppoll, fds, nfds, NULL, NULL, 0);
 }
 
-/* Uncancelable fcntl.  */
-__typeof (__fcntl) __fcntl64_nocancel;
-
-#if IS_IN (libc) || IS_IN (rtld)
-hidden_proto (__open_nocancel)
-hidden_proto (__open64_nocancel)
-hidden_proto (__openat_nocancel)
-hidden_proto (__openat64_nocancel)
-hidden_proto (__read_nocancel)
-hidden_proto (__pread64_nocancel)
-hidden_proto (__write_nocancel)
-hidden_proto (__close_nocancel)
-hidden_proto (__fcntl64_nocancel)
-#endif
-
 #endif /* NOT_CANCEL_H  */

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-11-01 13:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-01 13:08 [glibc] Apply asm redirection in not-cancel before first use 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).