summaryrefslogtreecommitdiffstats
path: root/unix
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2022-11-24 17:43:12 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2022-11-24 17:43:12 (GMT)
commita4ac44fccc008eb38b43511905b3797f9b0274df (patch)
tree730695afac0bc36ad34fc55c73465845d2cf48d6 /unix
parentec4cf7a9950b3987b1736ee072b787c0b5494d7f (diff)
downloadtcl-a4ac44fccc008eb38b43511905b3797f9b0274df.zip
tcl-a4ac44fccc008eb38b43511905b3797f9b0274df.tar.gz
tcl-a4ac44fccc008eb38b43511905b3797f9b0274df.tar.bz2
Fix gcc warning, seen on Ubuntu with select notifier
Diffstat (limited to 'unix')
-rw-r--r--unix/tclSelectNotfy.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/unix/tclSelectNotfy.c b/unix/tclSelectNotfy.c
index 732e4c9..fc77e77 100644
--- a/unix/tclSelectNotfy.c
+++ b/unix/tclSelectNotfy.c
@@ -938,7 +938,10 @@ TclAsyncNotifier(
*flagPtr = value;
if (!asyncPending) {
asyncPending = 1;
- write(triggerPipe, "S", 1);
+ if (write(triggerPipe, "S", 1) != 1) {
+ asyncPending = 0;
+ return 0;
+ };
}
return 1;
}