tnew prototypes - 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 ce2a378d46c0bcd00ec08b9bc4ad861c8aa28a2f
 (DIR) parent 74a69210695acc71f865a811865fb528b68343f3
 (HTM) Author: rsc <devnull@localhost>
       Date:   Thu, 10 Feb 2005 16:08:16 +0000
       
       new prototypes
       
       Diffstat:
         M include/9p.h                        |       1 +
         M include/9pclient.h                  |       4 ++++
         M include/auth.h                      |       5 +++++
         M include/libc.h                      |      11 ++++++++++-
       
       4 files changed, 20 insertions(+), 1 deletion(-)
       ---
 (DIR) diff --git a/include/9p.h b/include/9p.h
       t@@ -181,6 +181,7 @@ struct Srv {
                Tree*        tree;
                void                (*destroyfid)(Fid*);
                void                (*destroyreq)(Req*);
       +        void                (*start)(Srv*);
                void                (*end)(Srv*);
                void*        aux;
        
 (DIR) diff --git a/include/9pclient.h b/include/9pclient.h
       t@@ -28,6 +28,7 @@ vlong fsseek(CFid*, vlong, int);
        long fswrite(CFid*, void*, long);
        void fsclose(CFid*);
        void fsunmount(CFsys*);
       +void _fsunmount(CFsys*);        /* do not close fd */
        struct Dir;        /* in case there's no lib9.h */
        long fsdirread(CFid*, struct Dir**);
        long fsdirreadall(CFid*, struct Dir**);
       t@@ -37,9 +38,12 @@ int fsdirwstat(CFsys*, char*, struct Dir*);
        int fsdirfwstat(CFid*, struct Dir*);
        CFid *fsroot(CFsys*);
        void fssetroot(CFsys*, CFid*);
       +CFsys *nsinit(char*);
        CFsys *nsmount(char*, char*);
        CFid *nsopen(char*, char*, char*, int);
        
       +extern int chatty9pclient;
       +
        #ifdef __cplusplus
        }
        #endif
 (DIR) diff --git a/include/auth.h b/include/auth.h
       t@@ -152,6 +152,11 @@ extern Attr*                auth_attr(AuthRpc *rpc);
        extern void                auth_freerpc(AuthRpc *rpc);
        extern uint                auth_rpc(AuthRpc *rpc, char *verb, void *a, int n);
        extern int                auth_wep(char*, char*, ...);
       +
       +extern struct CFsys*        fsamount(int fd, char *aname);
       +extern struct CFsys* nsamount(char *name, char *aname);
       +
       +
        /*
        #pragma varargck argpos auth_proxy 3
        #pragma varargck argpos auth_challenge 1
 (DIR) diff --git a/include/libc.h b/include/libc.h
       t@@ -362,6 +362,7 @@ extern        double        fmtcharstod(int(*)(void*), void*);
        extern        char*        cleanname(char*);
        extern        int        p9decrypt(void*, void*, int);
        extern        int        p9encrypt(void*, void*, int);
       +extern        int        netcrypt(void*, void*);
        extern        int        dec64(uchar*, int, char*, int);
        extern        int        enc64(char*, int, uchar*, int);
        extern        int        dec32(uchar*, int, char*, int);
       t@@ -403,10 +404,12 @@ extern        vlong        strtoll(char*, char**, int);
        extern        uvlong        strtoull(char*, char**, int);
         */
        extern        void        sysfatal(char*, ...);
       +extern        void        p9syslog(int, char*, char*, ...);
        extern        long        p9time(long*);
        /* extern        int        tolower(int); <ctype.h> */
        /* extern        int        toupper(int); <ctype.h> */
        extern        void        needstack(int);
       +extern        char*        readcons(char*, char*, int);
        
        #ifndef NOPLAN9DEFINES
        #define atexit                p9atexit
       t@@ -428,6 +431,7 @@ extern        void        needstack(int);
        #define pow10                p9pow10
        #define strtod                fmtstrtod
        #define charstod        fmtcharstod
       +#define syslog                p9syslog
        #endif
        
        /*
       t@@ -590,6 +594,7 @@ extern        void                freenetconninfo(NetConnInfo*);
        #define ONONBLOCK 256        /* or'ed in, non-blocking call */
        #define        OEXCL        0x1000        /* or'ed in, exclusive use (create only) */
        #define        OLOCK        0x2000        /* or'ed in, lock after opening */
       +#define        OAPPEND        0x4000        /* or'ed in, append only */
        
        #define        AEXIST        0        /* accessible: exists */
        #define        AEXEC        1        /* execute access */
       t@@ -620,7 +625,11 @@ extern        void                freenetconninfo(NetConnInfo*);
        #define DMEXCL                0x20000000        /* mode bit for exclusive use files */
        #define DMMOUNT                0x10000000        /* mode bit for mounted channel */
        #define DMAUTH                0x08000000        /* mode bit for authentication file */
       -#define DMLINK                0x04000000        /* mode bit for symbolic link */
       +#define DMDEVICE                0x00800000        /* mode bit for device files (Unix) */
       +#define DMSYMLINK        0x00400000        /* mode bit for symbolic links (Unix) */
       +#define DMNAMEDPIPE        0x00200000        /* mode bit for named pipes (Unix) */
       +#define DMSOCKET                0x00100000        /* mode bit for sockets (Unix) */
       +
        #define DMREAD                0x4                /* mode bit for read permission */
        #define DMWRITE                0x2                /* mode bit for write permission */
        #define DMEXEC                0x1                /* mode bit for execute permission */