diff options
| author | Jim Blandy | 1993-06-09 12:41:31 +0000 |
|---|---|---|
| committer | Jim Blandy | 1993-06-09 12:41:31 +0000 |
| commit | 2fdfe0796e19aa31a7082aa705feb63086fb22e6 (patch) | |
| tree | e30a810097e0f262369afbfd5b159ac6db199aa8 | |
| parent | 6382623783831301f85010bd515aa3159c6d1354 (diff) | |
| download | emacs-2fdfe0796e19aa31a7082aa705feb63086fb22e6.tar.gz emacs-2fdfe0796e19aa31a7082aa705feb63086fb22e6.zip | |
* 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.
| -rw-r--r-- | lib-src/emacsserver.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib-src/emacsserver.c b/lib-src/emacsserver.c index fc5f33da985..769d87e1e8a 100644 --- a/lib-src/emacsserver.c +++ b/lib-src/emacsserver.c | |||
| @@ -108,7 +108,7 @@ main () | |||
| 108 | unlink (server.sun_path); | 108 | unlink (server.sun_path); |
| 109 | #endif | 109 | #endif |
| 110 | 110 | ||
| 111 | if (bind (s, &server, strlen (server.sun_path) + 2) < 0) | 111 | if (bind (s, (struct sockaddr *) &server, strlen (server.sun_path) + 2) < 0) |
| 112 | { | 112 | { |
| 113 | perror ("bind"); | 113 | perror ("bind"); |
| 114 | exit (1); | 114 | exit (1); |
| @@ -135,7 +135,7 @@ main () | |||
| 135 | { | 135 | { |
| 136 | fromlen = sizeof (fromunix); | 136 | fromlen = sizeof (fromunix); |
| 137 | fromunix.sun_family = AF_UNIX; | 137 | fromunix.sun_family = AF_UNIX; |
| 138 | infd = accept (s, &fromunix, &fromlen); /* open socket fd */ | 138 | infd = accept (s, (struct sockaddr *) &fromunix, &fromlen); /* open socket fd */ |
| 139 | if (infd < 0) | 139 | if (infd < 0) |
| 140 | { | 140 | { |
| 141 | if (errno == EMFILE || errno == ENFILE) | 141 | if (errno == EMFILE || errno == ENFILE) |