Merge pull request #125 from okeuday/master

Fix compilation for GCC (tested with 5.4.0)
This commit is contained in:
François-Xavier Bourlet 2018-09-22 23:20:17 -07:00 committed by GitHub
commit 06cfe31a34
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3704,10 +3704,14 @@ public:
SA_RESETHAND); SA_RESETHAND);
sigfillset(&action.sa_mask); sigfillset(&action.sa_mask);
sigdelset(&action.sa_mask, posix_signals[i]); sigdelset(&action.sa_mask, posix_signals[i]);
#if defined(__clang__)
#pragma clang diagnostic push #pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdisabled-macro-expansion" #pragma clang diagnostic ignored "-Wdisabled-macro-expansion"
#endif
action.sa_sigaction = &sig_handler; action.sa_sigaction = &sig_handler;
#if defined(__clang__)
#pragma clang diagnostic pop #pragma clang diagnostic pop
#endif
int r = sigaction(posix_signals[i], &action, nullptr); int r = sigaction(posix_signals[i], &action, nullptr);
if (r < 0) success = false; if (r < 0) success = false;