From 5d73649e1ef5d78a848e0177a8385da9365105c0 Mon Sep 17 00:00:00 2001
From: rswindell <>
Date: Fri, 9 Jan 2009 00:35:30 +0000
Subject: [PATCH] Define SHUT_WR (and SHUT_RD for kicks) for WinSock targets.

---
 src/xpdev/sockwrap.h | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/src/xpdev/sockwrap.h b/src/xpdev/sockwrap.h
index 4fd2cc40ba..285e06663b 100644
--- a/src/xpdev/sockwrap.h
+++ b/src/xpdev/sockwrap.h
@@ -8,7 +8,7 @@
  * @format.tab-size 4		(Plain Text/Source Code File Header)			*
  * @format.use-tabs true	(see http://www.synchro.net/ptsc_hdr.html)		*
  *																			*
- * Copyright 2008 Rob Swindell - http://www.synchro.net/copyright.html		*
+ * Copyright 2009 Rob Swindell - http://www.synchro.net/copyright.html		*
  *																			*
  * This library is free software; you can redistribute it and/or			*
  * modify it under the terms of the GNU Lesser General Public License		*
@@ -129,6 +129,11 @@ typedef struct {
 #undef	EINPROGRESS
 #define EINPROGRESS		(WSAEINPROGRESS-WSABASEERR)
 
+/* for shutdown() */
+#define SHUT_RD			SD_RECEIVE
+#define SHUT_WR			SD_SEND
+#define SHUT_RDWR		SD_BOTH
+
 #define s_addr			S_un.S_addr
 
 #define socklen_t		int
@@ -178,10 +183,6 @@ int 	retry_bind(SOCKET s, const struct sockaddr *addr, socklen_t addrlen
 }
 #endif
 
-#ifndef SHUT_RDWR
-#define SHUT_RDWR			2	/* for shutdown() */
-#endif
-
 #ifndef IPPORT_HTTP
 #define IPPORT_HTTP			80
 #endif
-- 
GitLab