mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-12-27 10:54:40 +00:00
* emacsserver.c (main): When we're passing a `struct sockaddr_un'
to bind or accept, cast the pointer, to avoid warnings on systems which declare prototypes for this.
This commit is contained in:
parent
6382623783
commit
2fdfe0796e
@ -108,7 +108,7 @@ main ()
|
||||
unlink (server.sun_path);
|
||||
#endif
|
||||
|
||||
if (bind (s, &server, strlen (server.sun_path) + 2) < 0)
|
||||
if (bind (s, (struct sockaddr *) &server, strlen (server.sun_path) + 2) < 0)
|
||||
{
|
||||
perror ("bind");
|
||||
exit (1);
|
||||
@ -135,7 +135,7 @@ main ()
|
||||
{
|
||||
fromlen = sizeof (fromunix);
|
||||
fromunix.sun_family = AF_UNIX;
|
||||
infd = accept (s, &fromunix, &fromlen); /* open socket fd */
|
||||
infd = accept (s, (struct sockaddr *) &fromunix, &fromlen); /* open socket fd */
|
||||
if (infd < 0)
|
||||
{
|
||||
if (errno == EMFILE || errno == ENFILE)
|
||||
|
Loading…
Reference in New Issue
Block a user