home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / CLIPPER / MISC / XBBS7200.ZIP / XBBS7200.TAR / msgpack / packdef.h < prev    next >
Encoding:
C/C++ Source or Header  |  1989-05-07  |  4.1 KB  |  157 lines

  1. /*
  2.     packdef.h
  3.  
  4.     Global defines and storage definitions for use by
  5.     file packing.
  6.         Last modification date: November 13, 1986
  7.  
  8. */
  9.  
  10. /* --------------------------------------------------------------------- */
  11. #include <stdio.h>
  12. #define MAXLINE 82
  13. #define CPMEOF 0x1a
  14. #define TRUE      1
  15. #define FALSE     0
  16. #define ERROR    -1
  17. #define OK        1
  18. #define READ      0
  19. #define WRITE     1
  20. #define UPDATE    2
  21. #define STDIN     0
  22. #define STDOUT    1
  23. #define CRLF      "\r\n"
  24. /* --------------------------------------------------------------------- */
  25.  
  26. #define HEADER      "header.bbs"    /* file name */
  27. #define MESSAGES  "messages.bbs"    /* file name */
  28. #define CROSSREF  "crossref.bbs"
  29. #define MSGLOG      "messages.log"
  30. #define NEWHEADER "Oheader.bbs"
  31. #define NEWXREF   "Ocrossref.bbs"
  32. #define NEWMSG    "Omessages.bbs"
  33. #define NEWLOG    "Omessages.log"
  34. #define LINKH      "Lhdr.bbs"
  35. #define LINKM     "Lmsg.bbs"
  36. #define LINKC     "Lxrf.bbs"
  37. #define CHMOD     "chmod 666 "
  38. #define CHMOD1      "*"
  39.  
  40. /*
  41. #define MSGS      "/user/bbsfiles/msgareas.bbs"
  42. */
  43.  
  44. #define    MSGS1      "msgareas.bbs"
  45.  
  46. /*
  47. #define ORGPATH   "/user/bbsfiles/"
  48. */
  49.  
  50. /*    defines used by the bbscfile.c routine     */
  51.  
  52. #define MSG1MAX 102        /* max. piece of message to put in 128 */
  53.                 /*  byte chunk of msg file */
  54. #define MSGSECT 128        /* size of message sector */
  55.  
  56. /*            end of defines used by the bbscfile.c routine */
  57.  
  58. char    ORGPATH[75];
  59. char    MSGS[99];
  60.  
  61.                 /* global variables */
  62. char    portin();        /* in routine returns a character */
  63. char    *gb4sin();        /* returns pointer to character */
  64.  
  65. FILE    *inbuf ;        /* handy input buffer pointer */
  66. FILE    *otbuf ;        /* another handy buffer pointer */
  67. FILE    *itbuf ;        /* pointer used to read/write user file */
  68. FILE    *rdstatbuf;
  69. FILE    *wtstatbuf;
  70. FILE    *STDerr;
  71.  
  72. char    w_fname[25];        /* first name on signon */
  73. char    w_lname[25];        /* last  name on signon */
  74. char    w_password[13];        /* password   on signon */
  75. char    *passptr;        /* ptr to password */
  76.  
  77.                 /* define user file fields */
  78. char    u_fname[25];
  79. char    u_lname[25];
  80. char    u_password[13];
  81. char    u_time1[12];        /* first time on system */
  82. char    u_date1[9];        /* first date on system */
  83. char    u_time2[12];        /* last  time on system */
  84. char    u_date2[9];        /* last  date on system */
  85. char    u_city[31];        /* city, state */
  86.  
  87. char    z_date[9];
  88.                 /* define message file fields    */
  89. char    msg_no[12];        /* message number */
  90. char    msg_date[10];        /* date of message */
  91. char    msg_time[16];        /* time of message */
  92. char    msg_to[22];        /* who message is to */
  93. char    msg_from[22];        /* who message is from */
  94. char    msg_pass[12];        /* password */
  95. char    msg_subject[22];    /* what it's all about */
  96. char    msg_text[7400];        /* text of message 20 lines */
  97.                 /*  by 72 wide */
  98. char    msg_delete[3];        /* indicates msg status */
  99.                 /*  0 = active */
  100.                 /*  9 = deleted */
  101.                 /*  5 = active private */
  102. char    pubpriv[2];        /* temporary message type */
  103.  
  104. char    z_mm[3];
  105. char    z_dd[3];
  106. char    z_yy[3];
  107. char    buf128[384];
  108.  
  109. int    mon_handle;        /* Monitor Handle */
  110. int    debug;            /* switch for debug mode */
  111. int    offline;        /* switch for offline mode */
  112. int    xpert;            /* switch */
  113. int    toggle;            /* switch for list mode */
  114. int    if_monitor;
  115. int    in_the_buffer;
  116. int    active;            /* indicates if logged on */
  117. int    statcnt;        /* count used for status routines */
  118. int    stop_that;        /* switch - true indicates ctl-K */
  119.                 /*  or K received in portout routine */
  120.                 /* date/time fields - used by bbsclock.c */
  121. char    mm[3];
  122. char    dd[3];
  123. char    yy[3];
  124. char    month[20];        /* ie. January */
  125. char    day[3];            /* dd */
  126. char    year[5];        /* 19yy */
  127. char    date[30];        /* ie. January 31, 1983 */ 
  128. char    week[20];        /* day of week Monday, Tuesday... */
  129. char    ttime[12];        /* time of day  HH:MM:SS xM */
  130.                 /*          where x = A or P */
  131.  
  132. /*            variables used by the bbscfile.c routine */
  133.  
  134. char    h_next_msg[10];        /* next avail. message # */
  135. char    h_date[10];        /* last update date of header file */
  136. char    h_act_msg[10];
  137. char    jnk[2];
  138. char    m_pathname[99];
  139. int    lnctx;
  140. int    h_act;
  141. int    h_next;            /* next avail. message # in integer */
  142. long    xtable[1000];
  143. long    ytable[1000];
  144.  
  145. long    d_pos;
  146. long    old_long_date;
  147. long    new_long_date;
  148. long    xmm;
  149. long    xdd;
  150. long    xyy;
  151.  
  152. /*            end of variables used by bbscfile.c */
  153.  
  154.             /* end of globals */
  155.  
  156. /* end of program */
  157.