This avoids changing the entire sigset_t structure. Updating the
actually used part is sufficient.
#include <errno.h>
#include <signal.h>
-#include <string.h>
+#include <sigsetops.h>
/* Clear all signals from SET. */
int
return -1;
}
- memset (set, 0, sizeof (sigset_t));
-
+ __sigemptyset (set);
return 0;
}
libc_hidden_def (sigemptyset)
#include <errno.h>
#include <signal.h>
-#include <string.h>
#include <internal-signals.h>
+#include <sigsetops.h>
/* Set all signals in SET. */
int
return -1;
}
- memset (set, 0xff, sizeof (sigset_t));
-
+ __sigfillset (set);
__clear_internal_signals (set);
-
return 0;
}
libc_hidden_def (sigfillset)