Noticed the build problem on i686-w64-mingw32 target as:
```
i686-w64-mingw32-gcc -c -DHAVE_CONFIG_H -DCROSS_COMPILING -I. -I.
-DRL_LIBRARY_VERSION='"8.1"' -DBRACKETED_PASTE_DEFAULT=1 -g -O2
-Wno-parentheses -Wno-format-security signals.c
signals.c: In function '_rl_handle_signal':
signals.c:270:2: warning: implicit declaration of function 'sigprocmask'
[-Wimplicit-function-declaration]
270 | sigprocmask (SIG_BLOCK, &set, &oset);
| ^~~~~~~~~~~
signals.c:270:15: error: 'SIG_BLOCK' undeclared (first use in this function);
did you mean 'SIG_ACK'?
270 | sigprocmask (SIG_BLOCK, &set, &oset);
| ^~~~~~~~~
| SIG_ACK
signals.c:270:15: note: each undec
```
The change guards sigprocmask() the same way SIG_UNBLOCK
is guarded a few lines below.
Signed-off-by: Sergei Trofimovich <[email protected]>
---
signals.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/signals.c b/signals.c
index f9174ab..8fedc37 100644
--- a/signals.c
+++ b/signals.c
@@ -266,8 +266,10 @@ _rl_handle_signal (int sig)
case SIGQUIT:
#endif
+#if defined (HAVE_POSIX_SIGNALS)
if (block_sig)
sigprocmask (SIG_BLOCK, &set, &oset);
+#endif
rl_echo_signal_char (sig);
rl_cleanup_after_signal ();
--
2.30.0