public inbox for cygwin-cvs@sourceware.org
help / color / mirror / Atom feed
From: Corinna Vinschen <corinna@sourceware.org>
To: cygwin-cvs@sourceware.org
Subject: [newlib-cygwin] Cygwin: socket.h: add socket options added in recent Windows releases
Date: Fri, 13 May 2022 10:15:47 +0000 (GMT)	[thread overview]
Message-ID: <20220513101547.C66923857C4A@sourceware.org> (raw)

https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=34a9570ff833a525fcb295988f9da3d357b290a9

commit 34a9570ff833a525fcb295988f9da3d357b290a9
Author: Corinna Vinschen <corinna@vinschen.de>
Date:   Wed May 4 20:24:06 2022 +0200

    Cygwin: socket.h: add socket options added in recent Windows releases
    
    Add new socket options equivalent to their Linux counterpart.
    
    Signed-off-by: Corinna Vinschen <corinna@vinschen.de>

Diff:
---
 winsup/cygwin/include/cygwin/socket.h | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/winsup/cygwin/include/cygwin/socket.h b/winsup/cygwin/include/cygwin/socket.h
index 0ca8300d9..33f18091c 100644
--- a/winsup/cygwin/include/cygwin/socket.h
+++ b/winsup/cygwin/include/cygwin/socket.h
@@ -248,10 +248,22 @@ struct OLD_msghdr
 #define IP_BLOCK_SOURCE                 17
 #define IP_UNBLOCK_SOURCE               18
 #define IP_PKTINFO                      19
+#define IP_RECVTTL                      21
 #define IP_UNICAST_IF                   31
+#define IP_RECVTOS                      40
+#define IP_MTU_DISCOVER                 71
+#define IP_MTU                          73
+#define IP_RECVERR                      75
+
+/* IP_MTU_DISCOVER optvals */
+#define IP_PMTUDISC_WANT                0	/* Use per route hints  */
+#define IP_PMTUDISC_DO                  1       /* Always DF            */
+#define IP_PMTUDISC_DONT                2       /* Never send DF frames */
+#define IP_PMTUDISC_PROBE               3       /* Ignore dst pmtu      */
 
 /* IPv6 options for use with getsockopt/setsockopt */
 #define IPV6_HOPOPTS                     1
+#define IPV6_HDRINCL                     2
 #define IPV6_UNICAST_HOPS                4
 #define IPV6_MULTICAST_IF                9
 #define IPV6_MULTICAST_HOPS             10
@@ -270,6 +282,15 @@ struct OLD_msghdr
 #define IPV6_RECVRTHDR                  38
 #define IPV6_TCLASS                     39
 #define IPV6_RECVTCLASS                 40
+#define IPV6_MTU_DISCOVER               71
+#define IPV6_MTU                        72
+#define IPV6_RECVERR                    75
+
+/* IPV6_MTU_DISCOVER optvals */
+#define IPV6_PMTUDISC_WANT              0	/* Use per route hints  */
+#define IPV6_PMTUDISC_DO                1       /* Always DF            */
+#define IPV6_PMTUDISC_DONT              2       /* Never send DF frames */
+#define IPV6_PMTUDISC_PROBE             3       /* Ignore dst pmtu      */
 
 /* IP agnostic options for use with getsockopt/setsockopt */
 #define MCAST_JOIN_GROUP                41


                 reply	other threads:[~2022-05-13 10:15 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220513101547.C66923857C4A@sourceware.org \
    --to=corinna@sourceware.org \
    --cc=cygwin-cvs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).