[BACK]Return to proto.h CVS log [TXT][DIR] Up to [local] / src / usr.bin / cvs

Annotation of src/usr.bin/cvs/proto.h, Revision 1.1

1.1     ! jfb         1: /*     $OpenBSD$       */
        !             2: /*
        !             3:  * Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
        !             4:  * All rights reserved.
        !             5:  *
        !             6:  * Redistribution and use in source and binary forms, with or without
        !             7:  * modification, are permitted provided that the following conditions
        !             8:  * are met:
        !             9:  *
        !            10:  * 1. Redistributions of source code must retain the above copyright
        !            11:  *    notice, this list of conditions and the following disclaimer.
        !            12:  * 2. The name of the author may not be used to endorse or promote products
        !            13:  *    derived from this software without specific prior written permission.
        !            14:  *
        !            15:  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
        !            16:  * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
        !            17:  * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
        !            18:  * THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
        !            19:  * EXEMPLARY, OR CONSEQUENTIAL  DAMAGES (INCLUDING, BUT NOT LIMITED TO,
        !            20:  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
        !            21:  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
        !            22:  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
        !            23:  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
        !            24:  * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        !            25:  */
        !            26:
        !            27: #ifndef PROTO_H
        !            28: #define PROTO_H
        !            29:
        !            30: #include <sys/param.h>
        !            31: #include <stdio.h>
        !            32: #include <dirent.h>
        !            33:
        !            34: #define CVS_REQ_TIMEOUT    300
        !            35:
        !            36:
        !            37: /* client/server protocol requests */
        !            38: #define CVS_REQ_NONE          0
        !            39: #define CVS_REQ_ROOT          1
        !            40: #define CVS_REQ_VALIDREQ      2
        !            41: #define CVS_REQ_VALIDRESP     3
        !            42: #define CVS_REQ_DIRECTORY     4
        !            43: #define CVS_REQ_MAXDOTDOT     5
        !            44: #define CVS_REQ_STATICDIR     6
        !            45: #define CVS_REQ_STICKY        7
        !            46: #define CVS_REQ_ENTRY         8
        !            47: #define CVS_REQ_ENTRYEXTRA    9
        !            48: #define CVS_REQ_CHECKINTIME  10
        !            49: #define CVS_REQ_MODIFIED     11
        !            50: #define CVS_REQ_ISMODIFIED   12
        !            51: #define CVS_REQ_UNCHANGED    13
        !            52: #define CVS_REQ_USEUNCHANGED 14
        !            53: #define CVS_REQ_NOTIFY       15
        !            54: #define CVS_REQ_NOTIFYUSER   16
        !            55: #define CVS_REQ_QUESTIONABLE 17
        !            56: #define CVS_REQ_CASE         18
        !            57: #define CVS_REQ_UTF8         19
        !            58: #define CVS_REQ_ARGUMENT     20
        !            59: #define CVS_REQ_ARGUMENTX    21
        !            60: #define CVS_REQ_GLOBALOPT    22
        !            61: #define CVS_REQ_GZIPSTREAM   23
        !            62: #define CVS_REQ_KERBENCRYPT  24
        !            63: #define CVS_REQ_GSSENCRYPT   25
        !            64: #define CVS_REQ_PROTOENCRYPT 26
        !            65: #define CVS_REQ_GSSAUTH      27
        !            66: #define CVS_REQ_PROTOAUTH    28
        !            67: #define CVS_REQ_READCVSRC2   29
        !            68: #define CVS_REQ_READWRAP     30
        !            69: #define CVS_REQ_ERRIFREADER  31
        !            70: #define CVS_REQ_VALIDRCSOPT  32
        !            71: #define CVS_REQ_READIGNORE   33
        !            72: #define CVS_REQ_SET          34
        !            73: #define CVS_REQ_XPANDMOD     35
        !            74: #define CVS_REQ_CI           36
        !            75: #define CVS_REQ_CHOWN        37
        !            76: #define CVS_REQ_SETOWN       38
        !            77: #define CVS_REQ_SETPERM      39
        !            78: #define CVS_REQ_CHACL        40
        !            79: #define CVS_REQ_LISTPERM     41
        !            80: #define CVS_REQ_LISTACL      42
        !            81: #define CVS_REQ_SETPASS      43
        !            82: #define CVS_REQ_PASSWD       44
        !            83: #define CVS_REQ_DIFF         45
        !            84: #define CVS_REQ_STATUS       46
        !            85: #define CVS_REQ_LS           47
        !            86: #define CVS_REQ_TAG          48
        !            87: #define CVS_REQ_IMPORT       49
        !            88: #define CVS_REQ_ADMIN        50
        !            89: #define CVS_REQ_HISTORY      51
        !            90: #define CVS_REQ_WATCHERS     52
        !            91: #define CVS_REQ_EDITORS      53
        !            92: #define CVS_REQ_ANNOTATE     54
        !            93: #define CVS_REQ_LOG          55
        !            94: #define CVS_REQ_CO           56
        !            95: #define CVS_REQ_EXPORT       57
        !            96: #define CVS_REQ_RANNOTATE    58
        !            97: #define CVS_REQ_INIT         59
        !            98: #define CVS_REQ_UPDATE       60
        !            99: #define CVS_REQ_ADD          62
        !           100: #define CVS_REQ_REMOVE       63
        !           101: #define CVS_REQ_NOOP         64
        !           102: #define CVS_REQ_RTAG         65
        !           103: #define CVS_REQ_RELEASE      66
        !           104: #define CVS_REQ_RLOG         67
        !           105: #define CVS_REQ_RDIFF        68
        !           106: #define CVS_REQ_VERSION      69
        !           107:
        !           108: #define CVS_REQ_MAX          69
        !           109:
        !           110:
        !           111: /* responses */
        !           112: #define CVS_RESP_OK           1
        !           113: #define CVS_RESP_ERROR        2
        !           114: #define CVS_RESP_VALIDREQ     3
        !           115: #define CVS_RESP_CHECKEDIN    4
        !           116: #define CVS_RESP_NEWENTRY     5
        !           117: #define CVS_RESP_CKSUM        6
        !           118: #define CVS_RESP_COPYFILE     7
        !           119: #define CVS_RESP_UPDATED      8
        !           120: #define CVS_RESP_CREATED      9
        !           121: #define CVS_RESP_UPDEXIST    10
        !           122: #define CVS_RESP_MERGED      11
        !           123: #define CVS_RESP_PATCHED     12
        !           124: #define CVS_RESP_RCSDIFF     13
        !           125: #define CVS_RESP_MODE        14
        !           126: #define CVS_RESP_MODTIME     15
        !           127: #define CVS_RESP_REMOVED     16
        !           128: #define CVS_RESP_RMENTRY     17
        !           129: #define CVS_RESP_SETSTATDIR  18
        !           130: #define CVS_RESP_CLRSTATDIR  19
        !           131: #define CVS_RESP_SETSTICKY   20
        !           132: #define CVS_RESP_CLRSTICKY   21
        !           133: #define CVS_RESP_TEMPLATE    22
        !           134: #define CVS_RESP_SETCIPROG   23
        !           135: #define CVS_RESP_SETUPDPROG  24
        !           136: #define CVS_RESP_NOTIFIED    25
        !           137: #define CVS_RESP_MODXPAND    26
        !           138: #define CVS_RESP_WRAPRCSOPT  27
        !           139: #define CVS_RESP_M           28
        !           140: #define CVS_RESP_MBINARY     29
        !           141: #define CVS_RESP_E           30
        !           142: #define CVS_RESP_F           31
        !           143: #define CVS_RESP_MT          32
        !           144:
        !           145:
        !           146:
        !           147: int         cvs_sendfile       (struct cvsroot *, const char *);
        !           148: int         cvs_recvfile       (struct cvsroot *, const char *);
        !           149: int         cvs_connect        (struct cvsroot *);
        !           150: void        cvs_disconnect     (struct cvsroot *);
        !           151:
        !           152: int             cvs_req_handle     (char *);
        !           153: struct cvs_req* cvs_req_getbyid    (int);
        !           154: struct cvs_req* cvs_req_getbyname  (const char *);
        !           155: char*           cvs_req_getvalid   (void);
        !           156:
        !           157: int              cvs_resp_handle    (struct cvsroot *, char *);
        !           158: struct cvs_resp* cvs_resp_getbyid   (int);
        !           159: struct cvs_resp* cvs_resp_getbyname (const char *);
        !           160: char*            cvs_resp_getvalid  (void);
        !           161:
        !           162: int         cvs_sendreq     (struct cvsroot *, u_int, const char *);
        !           163: int         cvs_getresp     (struct cvsroot *);
        !           164: int         cvs_getln       (struct cvsroot *, char *, size_t);
        !           165: int         cvs_senddir     (struct cvsroot *, CVSFILE *);
        !           166: int         cvs_sendarg     (struct cvsroot *, const char *, int);
        !           167: int         cvs_sendln      (struct cvsroot *, const char *);
        !           168: int         cvs_sendentry   (struct cvsroot *, const struct cvs_ent *);
        !           169: int         cvs_sendraw     (struct cvsroot *, const void *, size_t);
        !           170: ssize_t     cvs_recvraw     (struct cvsroot *, void *, size_t);
        !           171:
        !           172:
        !           173: #endif /* PROTO_H */