VirtualBox

Ticket #9227: netif_freebsd.diff

File netif_freebsd.diff, 1.1 KB (added by Robert Millan, 13 years ago)
  • src/VBox/Main/src-server/freebsd/NetIf-freebsd.cpp

     
    4444#include <netinet/in.h>
    4545
    4646#include <stdio.h>
     47#include <stdlib.h>     /* malloc, free */
    4748#include <unistd.h>
    4849#include <errno.h>
    4950
     
    159160            if (!pInfo->IPv6Address.s.Lo && !pInfo->IPv6Address.s.Hi)
    160161            {
    161162                memcpy(pInfo->IPv6Address.au8,
    162                        ((struct sockaddr_in6 *)addresses[RTAX_IFA])->sin6_addr.__u6_addr.__u6_addr8,
     163                       ((struct sockaddr_in6 *)addresses[RTAX_IFA])->sin6_addr.s6_addr,
    163164                       sizeof(pInfo->IPv6Address));
    164165                memcpy(pInfo->IPv6NetMask.au8,
    165                        ((struct sockaddr_in6 *)addresses[RTAX_NETMASK])->sin6_addr.__u6_addr.__u6_addr8,
     166                       ((struct sockaddr_in6 *)addresses[RTAX_NETMASK])->sin6_addr.s6_addr,
    166167                       sizeof(pInfo->IPv6NetMask));
    167168            }
    168169            break;

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy