aboutsummaryrefslogtreecommitdiff
path: root/src/lib9/_p9dialparse.c
diff options
context:
space:
mode:
authorrsc <devnull@localhost>2003-11-23 19:49:17 +0000
committerrsc <devnull@localhost>2003-11-23 19:49:17 +0000
commit1c253ceb586c4519f42ce115954c4efab787f81a (patch)
tree22281aafc4c33f4ab310a845aec510f013511833 /src/lib9/_p9dialparse.c
parent50e628cb8f4594b7cbccc17ff3f701ff260a69c0 (diff)
downloadplan9port-1c253ceb586c4519f42ce115954c4efab787f81a.tar.gz
plan9port-1c253ceb586c4519f42ce115954c4efab787f81a.tar.bz2
plan9port-1c253ceb586c4519f42ce115954c4efab787f81a.zip
Annoying changes to work on Sun boxes.
Diffstat (limited to 'src/lib9/_p9dialparse.c')
-rw-r--r--src/lib9/_p9dialparse.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib9/_p9dialparse.c b/src/lib9/_p9dialparse.c
index 93c98425..44594dc0 100644
--- a/src/lib9/_p9dialparse.c
+++ b/src/lib9/_p9dialparse.c
@@ -1,9 +1,9 @@
-#include <u.h>
-#include <libc.h>
-
#include <netdb.h>
#include <sys/un.h>
+#include <u.h>
+#include <libc.h>
+
static char *nets[] = { "tcp", "udp", nil };
#define CLASS(p) ((*(uchar*)(p))>>6)
@@ -59,7 +59,7 @@ _p9dialparse(char *addr, char **pnet, char **punix, u32int *phost, int *pport)
int i;
struct servent *se;
struct hostent *he;
- struct sockaddr_un *sun;
+ struct sockaddr_un *sockun;
if(strncmp(addr, "/net/", 5) == 0)
addr += 5;
@@ -73,7 +73,7 @@ _p9dialparse(char *addr, char **pnet, char **punix, u32int *phost, int *pport)
if((port = strchr(host, '!')) == nil){
if(strcmp(net, "unix")==0 || strcmp(net, "net")==0){
Unix:
- if(strlen(host)+1 > sizeof sun->sun_path){
+ if(strlen(host)+1 > sizeof sockun->sun_path){
werrstr("unix socket name too long");
return -1;
}