Changeset 320

Show
Ignore:
Timestamp:
05/16/07 10:21:51 (2 years ago)
Author:
blackhedd
Message:

Applied patches supplied by Brett Eisenberg.
Evidently on Solaris, "sun" is a reserved word and can't be
used as an identifier name.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • version_0/ChangeLog

    r304 r320  
    1818 19Dec06: Added EventMachine#set_effective_user. 
    1919 05Jan07: Upped max outstanding timers to 1000. 
     20 15May07: Applied Solaris patches from Brett Eisenberg 
  • version_0/ext/em.cpp

    r314 r320  
    962962        const char *output_binding = NULL; 
    963963 
    964         struct sockaddr_un sun; 
     964        struct sockaddr_un s_sun; 
    965965 
    966966        int sd_accept = socket (AF_LOCAL, SOCK_STREAM, 0); 
     
    973973        unlink (filename); 
    974974 
    975         bzero (&sun, sizeof(sun)); 
    976         sun.sun_family = AF_LOCAL; 
    977         strncpy (sun.sun_path, filename, sizeof(sun.sun_path)-1); 
     975        bzero (&s_sun, sizeof(s_sun)); 
     976        s_sun.sun_family = AF_LOCAL; 
     977        strncpy (s_sun.sun_path, filename, sizeof(s_sun.sun_path)-1); 
    978978 
    979979        // don't bother with reuseaddr for a local socket. 
     
    988988        } 
    989989 
    990         if (bind (sd_accept, (struct sockaddr*)&sun, sizeof(sun))) { 
     990        if (bind (sd_accept, (struct sockaddr*)&s_sun, sizeof(s_sun))) { 
    991991                //__warning ("binding failed"); 
    992992                goto fail; 
  • version_0/ext/project.h

    r319 r320  
    6767#define AF_LOCAL AF_UNIX 
    6868#endif 
    69 #define INADDR_NONE ((unsigned long)-1) 
     69// The ff is superfluous on Solaris > 7. Thanks to Brett Eisenberg. 
     70//#define INADDR_NONE ((unsigned long)-1) 
    7071#endif 
    7172#endif