reading from a ipv6 tunnel

view story

http://askubuntu.com – Hi I have a program that creates a tun interface for both IPv4 and IPv6. I can see the packets by reading/writing the packets through read/write functions but in case of IPv6 It seems the same read/write functions never get called. Is reading/writing Tun interface different for v4 and v6? :( platform :3.2.0-23-generic-pae #36-Ubuntu SMP Tue Apr 10 22:19:09 UTC 2012 i686 i686 i386 GNU/Linux (Ubuntu 12.04) code: int fd = 0; int err = 0; int sockfd = 0; int dev_num = 0; struct ifreq ifr; struct in6_ifreq ifr6; if( (fd = open("/dev/net/tun", O_RDWR)) < 0 ) { print (HowTos)