aboutsummaryrefslogtreecommitdiffstats
path: root/transact.c
diff options
context:
space:
mode:
Diffstat (limited to 'transact.c')
-rw-r--r--transact.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/transact.c b/transact.c
index 247d3e65..f9328df2 100644
--- a/transact.c
+++ b/transact.c
@@ -1503,7 +1503,10 @@ va_dcl
va_end(ap);
snprintf(buf+strlen(buf), sizeof(buf)-strlen(buf), "\r\n");
- SockWrite(sock, buf, strlen(buf));
+ if (SockWrite(sock, buf, strlen(buf)) < strlen(buf)) {
+ /* short write, bail out */
+ return PS_SOCKET;
+ }
if (outlevel >= O_MONITOR)
{