Changeset 3692 for pjproject


Ignore:
Timestamp:
Aug 11, 2011 8:45:38 AM (13 years ago)
Author:
ming
Message:

Fixed #1342: disable local host resolution on iPhone OS

Location:
pjproject/branches/1.x/pjlib
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • pjproject/branches/1.x/pjlib/include/pj/compat/os_auto.h.in

    r3543 r3692  
    178178        /* Use CFHost API for pj_getaddrinfo() (see ticket #1246) */ 
    179179#       define PJ_GETADDRINFO_USE_CFHOST 1 
     180        /* Disable local host resolution in pj_gethostip() (see ticket #1342) */ 
     181#       define PJ_GETHOSTIP_DISABLE_LOCAL_RESOLUTION 1 
    180182#       ifdef __IPHONE_4_0 
    181183            /* Is multitasking support available?  (see ticket #1107) */ 
  • pjproject/branches/1.x/pjlib/src/pj/sock_common.c

    r3553 r3692  
    785785    PJ_SOCKADDR_RESET_LEN(addr); 
    786786 
     787#if defined(PJ_GETHOSTIP_DISABLE_LOCAL_RESOLUTION) && \ 
     788    PJ_GETHOSTIP_DISABLE_LOCAL_RESOLUTION == 1 
    787789    /* Get hostname's IP address */ 
    788790    count = 1; 
     
    798800                pj_sockaddr_print(&ai.ai_addr, strip, sizeof(strip), 0))); 
    799801    } 
    800  
     802#else 
     803    PJ_UNUSED_ARG(ai); 
     804    PJ_UNUSED_ARG(count); 
     805#endif 
    801806 
    802807    /* Get default interface (interface for default route) */ 
Note: See TracChangeset for help on using the changeset viewer.