tannounce to networks - plan9port - [fork] Plan 9 from user space
 (HTM) git clone git://src.adamsgaard.dk/plan9port
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit 9f95eb6fd6e5fa8a3be78f8b1b85310f50e49380
 (DIR) parent 16ea7713b5a20cfb8482d4a65f40760cc67c999b
 (HTM) Author: rsc <devnull@localhost>
       Date:   Mon, 18 Jul 2005 00:05:41 +0000
       
       announce to networks
       
       Diffstat:
         M src/lib9/post9p.c                   |      13 ++++++++-----
       
       1 file changed, 8 insertions(+), 5 deletions(-)
       ---
 (DIR) diff --git a/src/lib9/post9p.c b/src/lib9/post9p.c
       t@@ -8,11 +8,14 @@ post9pservice(int fd, char *name)
                char *ns, *s;
                Waitmsg *w;
        
       -        if((ns = getns()) == nil)
       -                return -1;
       -
       -        s = smprint("unix!%s/%s", ns, name);
       -        free(ns);
       +        if(strchr(name, '!'))        /* assume is already network address */
       +                s = strdup(name);
       +        else{
       +                if((ns = getns()) == nil)
       +                        return -1;
       +                s = smprint("unix!%s/%s", ns, name);
       +                free(ns);
       +        }
                if(s == nil)
                        return -1;
                switch(fork()){