File tree Expand file tree Collapse file tree 2 files changed +22
-2
lines changed
compiler-rt/lib/sanitizer_common Expand file tree Collapse file tree 2 files changed +22
-2
lines changed Original file line number Diff line number Diff line change @@ -475,6 +475,8 @@ CHECK_TYPE_SIZE(nfds_t);
475
475
CHECK_TYPE_SIZE (sigset_t );
476
476
477
477
COMPILER_CHECK (sizeof (__sanitizer_sigaction) == sizeof(struct sigaction ));
478
+ COMPILER_CHECK (sizeof (__sanitizer_siginfo) == sizeof(siginfo_t ));
479
+ CHECK_SIZE_AND_OFFSET (siginfo_t , si_value);
478
480
// Can't write checks for sa_handler and sa_sigaction due to them being
479
481
// preprocessor macros.
480
482
CHECK_STRUCT_SIZE_AND_OFFSET (sigaction, sa_mask);
Original file line number Diff line number Diff line change @@ -301,11 +301,29 @@ struct __sanitizer_sigset_t {
301
301
302
302
typedef __sanitizer_sigset_t __sanitizer_kernel_sigset_t ;
303
303
304
+ union __sanitizer_sigval {
305
+ int sival_int;
306
+ void *sival_ptr;
307
+ };
308
+
304
309
struct __sanitizer_siginfo {
305
- // The size is determined by looking at sizeof of real siginfo_t on linux.
306
- u64 opaque[128 / sizeof (u64 )];
310
+ int si_signo;
311
+ int si_errno;
312
+ int si_code;
313
+ pid_t si_pid;
314
+ u32 si_uid;
315
+ int si_status;
316
+ void *si_addr;
317
+ union __sanitizer_sigval si_value;
318
+ # if SANITIZER_WORDSIZE == 64
319
+ char data[40 ];
320
+ # else
321
+ char data[32 ];
322
+ # endif
307
323
};
308
324
325
+ typedef __sanitizer_siginfo __sanitizer_siginfo_t ;
326
+
309
327
using __sanitizer_sighandler_ptr = void (*)(int sig);
310
328
using __sanitizer_sigactionhandler_ptr = void (*)(int sig,
311
329
__sanitizer_siginfo *siginfo,
You can’t perform that action at this time.
0 commit comments