home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 35 Internet / 35-Internet.zip / lpopper.zip / popper.h < prev    next >
C/C++ Source or Header  |  1999-11-09  |  2KB  |  113 lines

  1. #include <stdio.h>
  2. #include <string.h>
  3. #include <unistd.h>
  4. #include <malloc.h>
  5. #include <stdlib.h>
  6. #include <sys/types.h>
  7. #include <io.h>
  8. #include <fcntl.h>
  9. #include <getopt.h>
  10. #include <errno.h>
  11. #include <sys/types.h>
  12. #include <sys/wait.h>
  13. #include <sys/socket.h>
  14. #include <sys/ioctl.h>
  15. #include <netinet/in.h>
  16. #include <arpa/inet.h>
  17. #include <netdb.h>
  18. #include <share.h>
  19. #include <signal.h>
  20. #include <time.h>
  21.  
  22. int IsSpace( char Ch);
  23. int IsEmpty (char * Str);
  24. void DelEndSpaces( char * Str);
  25. void DelBegSpaces( char * Str);
  26. void DelSpaces (char * Str);
  27. int IsCRLF (char Ch);
  28. void DelEndCRLF (char * Str);
  29. unsigned char cDOS2KOI (unsigned char Ch);
  30.  
  31. struct Pwd
  32.  { char User[19];
  33.    char Pass[19];
  34.  };
  35.  
  36. enum Status 
  37.  { None=0,
  38.    Unreaded=1,
  39.    Readed=2,
  40.    Old=4,
  41.    ROld=6
  42.  };
  43.  
  44. struct Letter
  45.  { long Begin;
  46.    long End;
  47.    long Size;
  48.    char Deleted;
  49.    char Is866;
  50.    long cBeg;
  51.    long cEnd;
  52.    char * msgID;
  53.    char noID;
  54.  
  55.    int Lines;
  56.  
  57.    enum Status Status;
  58.    enum Status oStatus;
  59.    long sBeg;
  60.    long sEnd;
  61.    long hEnd;
  62.  
  63.    char NoCharset;
  64.  
  65. /*
  66.    long lineFirst;
  67.    long lineLast;
  68.    long lineEndHead;
  69.    long lineSubject;
  70.    long lineContent;
  71. */
  72.  };
  73.  
  74. int ReadUser (struct Pwd * uPw, char * Passwd);
  75.  
  76. int SkGetS (int Sk, char * Buf);
  77. int WaitConn(void);
  78.  
  79. int DoCommand(int Socket);
  80.  
  81. extern int Debug;
  82.  
  83. int CopyBlock (FILE * fFrom, FILE * fTo, long From, long To);
  84. int AddBlock (FILE * fTo, char * Str);
  85.  
  86. extern char MyName[];
  87. extern char TimeStamp[];
  88.  
  89.  
  90.  
  91. extern int Debug;
  92.  
  93. extern struct Letter  *mBox;
  94. extern long msgCount;
  95. extern long TotalLen;
  96. extern long uMsgCount;
  97. extern long uTotalLen;
  98. extern char PwdPath[];
  99. extern char BoxPath[];
  100.  
  101. void PrintTime (void);
  102. void ePrintTime (void);
  103.  
  104.  
  105. int CheckBox (char * rBox, char * tBox);
  106. int RescanBox(FILE * fBox);
  107. int PackBox(char * User, int DoDelete);
  108.  
  109.  
  110.  
  111.  
  112.  
  113.