Annotation of researchv9/ipc/src/libipc/ipcpath.c, revision 1.1

1.1     ! root        1: #include "defs.h"
        !             2: #include <signal.h>
        !             3: 
        !             4: #define CAT(x) if (x) for(cp=x;bp-buf<sizeof(buf)-1&&*cp;) *bp++= *cp++; *bp='\0'
        !             5: 
        !             6: char *
        !             7: ipcpath(machine, defdialer, service)
        !             8:        char *machine;
        !             9:        char *defdialer;
        !            10:        char *service;
        !            11: {
        !            12:        static char buf[256];
        !            13:        char *bp;
        !            14:        char *cp;
        !            15: 
        !            16:        bp = buf;
        !            17:        if (machine!=NULL && *machine!='\0') {
        !            18:                CAT(CSROOT);
        !            19:                if (strchr(machine, '!')==NULL){
        !            20:                        CAT(defdialer);
        !            21:                        CAT("!");
        !            22:                }
        !            23:        }
        !            24:        CAT(machine);
        !            25:        if (buf[0]=='\0') {
        !            26:                CAT(CSROOT);
        !            27:        } else if (service!=NULL && *service!='\0') {
        !            28:                CAT("!");
        !            29:        }
        !            30:        CAT(service);
        !            31:        return buf;
        !            32: }

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.