LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 12-02-2008, 06:40 AM   #1
deb1513
LQ Newbie
 
Registered: Nov 2008
Posts: 6

Rep: Reputation: 0
error: ‘struct in6_addr’ has no member named ‘in6_u’


Hi,

while compiling my program in Fedora version- 9 i am getting the following compilation error.

error: ‘struct in6_addr’ has no member named ‘in6_u’

The same program is running in other Fedora versions like Fedora 8 and Fedora 6.

Can any one tell me what is solution for this. I have the snap shot of my prog,

struct sockaddr_in6* sin6 = (struct sockaddr_in6*)&curr->addr;

sin6->sin6_family = AF_INET6;
memcpy (&sin6->sin6_addr.in6_u.u6_addr8,
addr, sizeof(sin6->sin6_addr.in6_u.u6_addr8));


After compilation getting error,

error: ‘struct in6_addr’ has no member named ‘in6_u’
 
Old 12-02-2008, 06:56 AM   #2
dmail
Member
 
Registered: Oct 2005
Posts: 970

Rep: Reputation: Disabled
Quote:
The <netinet/in.h> header shall define the in6_addr structure that contains at least the following member:

uint8_t s6_addr[16]
http://www.opengroup.org/onlinepubs/...inet/in.h.html
Code:
memcpy(&sin6->sin6_addr, addr, sizeof(in6_addr));
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
error: 'struct SDL_SysWMinfo' has no member named 'info' TiDjY Linux - Desktop 4 11-24-2008 06:00 AM
GCC compile problem:struct A have a member variable which is just a struct type name? leon.zcom Programming 3 04-18-2008 04:40 PM
error: ‘struct tcphdr’ has no member named ‘th_flags’ nasim751 Linux - Software 0 04-17-2008 05:55 AM
error: ‘struct inode’ has no member named ‘u’ PankajDS Linux - Kernel 0 02-25-2008 11:34 PM
access struct member error true_atlantis Programming 4 04-25-2006 05:00 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:17 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration