Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!sdd.hp.com!uakari.primate.wisc.edu!ra!uvaarpa!mmdf From: marc@athena.mit.edu (Marc Horowitz) Newsgroups: comp.lang.perl Subject: aligment problem in doio.c Message-ID: <1991May22.014547.17530@uvaarpa.Virginia.EDU> Date: 22 May 91 01:45:47 GMT Sender: mmdf@uvaarpa.Virginia.EDU (Uvaarpa Mail System) Reply-To: Marc Horowitz Organization: The Internet Lines: 16 in doio.c, line 1403: fd = accept(fileno(gstio->ifp),buf,&len); buf is declared as extern char buf[1024], and the second arg is a struct sockaddr * On my ansi system with prototypes (using RT hc2.1y), I get an error from the compiler. It was pointed out to me that you can't depend on the alignment of the char array to work for a structure. Actually, we know what's in there, so it shouldn't matter, but still, it can be considered an error by the compiler. Since you str_nset the pointer value of buf, I'm not sure what the solution is. For now, I stuck a cast in so I could build it. Marc