Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(170)

Side by Side Diff: fusl/src/signal/block.c

Issue 1714623002: [fusl] clang-format fusl (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: headers too Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 #include "pthread_impl.h" 1 #include "pthread_impl.h"
2 #include "syscall.h" 2 #include "syscall.h"
3 #include <signal.h> 3 #include <signal.h>
4 4
5 static const unsigned long all_mask[] = { 5 static const unsigned long all_mask[] = {
6 #if ULONG_MAX == 0xffffffff && _NSIG == 129 6 #if ULONG_MAX == 0xffffffff && _NSIG == 129
7 » -1UL, -1UL, -1UL, -1UL 7 -1UL, -1UL, -1UL, -1UL
8 #elif ULONG_MAX == 0xffffffff 8 #elif ULONG_MAX == 0xffffffff
9 » -1UL, -1UL 9 -1UL, -1UL
10 #else 10 #else
11 » -1UL 11 -1UL
12 #endif 12 #endif
13 }; 13 };
14 14
15 static const unsigned long app_mask[] = { 15 static const unsigned long app_mask[] = {
16 #if ULONG_MAX == 0xffffffff 16 #if ULONG_MAX == 0xffffffff
17 #if _NSIG == 65 17 #if _NSIG == 65
18 » 0x7fffffff, 0xfffffffc 18 0x7fffffff, 0xfffffffc
19 #else 19 #else
20 » 0x7fffffff, 0xfffffffc, -1UL, -1UL 20 0x7fffffff, 0xfffffffc, -1UL, -1UL
21 #endif 21 #endif
22 #else 22 #else
23 #if _NSIG == 65 23 #if _NSIG == 65
24 » 0xfffffffc7fffffff 24 0xfffffffc7fffffff
25 #else 25 #else
26 » 0xfffffffc7fffffff, -1UL 26 0xfffffffc7fffffff, -1UL
27 #endif 27 #endif
28 #endif 28 #endif
29 }; 29 };
30 30
31 void __block_all_sigs(void *set) 31 void __block_all_sigs(void* set) {
32 { 32 __syscall(SYS_rt_sigprocmask, SIG_BLOCK, &all_mask, set, _NSIG / 8);
33 » __syscall(SYS_rt_sigprocmask, SIG_BLOCK, &all_mask, set, _NSIG/8);
34 } 33 }
35 34
36 void __block_app_sigs(void *set) 35 void __block_app_sigs(void* set) {
37 { 36 __syscall(SYS_rt_sigprocmask, SIG_BLOCK, &app_mask, set, _NSIG / 8);
38 » __syscall(SYS_rt_sigprocmask, SIG_BLOCK, &app_mask, set, _NSIG/8);
39 } 37 }
40 38
41 void __restore_sigs(void *set) 39 void __restore_sigs(void* set) {
42 { 40 __syscall(SYS_rt_sigprocmask, SIG_SETMASK, set, 0, _NSIG / 8);
43 » __syscall(SYS_rt_sigprocmask, SIG_SETMASK, set, 0, _NSIG/8);
44 } 41 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698