Am Donnerstag 25 Januar 2007 09:46 schrieb Marcel Holtmann:
> > > > tcpobex.patch
> > >
> > > Please redo this since it no longer applies cleanly and keep a
> > > whitspace after the comma in parameter list. Also for pointers, the *
> > > belongs to the variable and not the type.
> >
> > I hope I got them all.
>
> The patch has been comnitted. Thanks.
There is one addition: although the "IPv6 with IPv4-mapped" should work for
all systems that use a dual-stack, some of them do disable the IPv4-mapped
support by default. Thus, it must be enabled. The attached patch does this.
Known default values for this IPv4 mapping:
Linux: on
Windows Vista: off
Side note: all modern system like Linux and Windows Vista (I do not consider
Windows XP to be a modern system) do use a dual-stack for IPv4/6. The
IPv4-mapped-addresses mechanism is system internal and thus unlikely to go
away anytime soon (which is good). I am not sure about the *BSDs, though:
there are various information about them around and all pieces of information
are telling something different.
You can assume a dual-stack if IPV6_V6ONLY is defined, I guess.
This patch is _not_ needed for Linux (it simply won't make a difference).
HS
Index: openobex-anoncvs/lib/inobex.c
===================================================================
--- openobex-anoncvs.orig/lib/inobex.c 2007-01-26 20:03:20.589735695 +0100
+++ openobex-anoncvs/lib/inobex.c 2007-01-28 09:32:16.335094648 +0100
@@ -164,6 +165,17 @@
DEBUG(0, "Cannot create server-socket\n");
return -1;
}
+#ifdef IPV6_V6ONLY
+ else {
+ /* Needed for some system that set this IPv6 socket option to
+ * 1 by default (Windows Vista, maybe some BSDs).
+ * Do not check the return code as it may not matter.
+ * You will certainly notice later if it failed.
+ */
+ int v6only = 0;
+ (void)setsockopt(self->serverfd,IPPROTO_IPV6,IPV6_V6ONLY,&v6only,sizeof(v6only));
+ }
+#endif
//printf("TCP/IP listen %d %X\n", self->trans.self.inet.sin_port,
// self->trans.self.inet.sin_addr.s_addr);
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Openobex-users mailing list
[email protected]
http://lists.sourceforge.net/lists/listinfo/openobex-users