home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / misc / volume38 / libftp / part01 / FtpWrite.c < prev    next >
Encoding:
C/C++ Source or Header  |  1993-07-13  |  279 b   |  18 lines

  1. #include "FtpLibrary.h"
  2.  
  3. int FtpWrite(FTP *con,char c)
  4. {
  5.   int i;
  6.   
  7.   if ( con -> mode == 'I' )
  8.     return putc(c,con->data);
  9.   if ( c == '\n' )
  10.     {
  11.       putc(Ctrl('M'),con->data);
  12.       i=putc(Ctrl('J'),con->data);
  13.     }
  14.   else
  15.     i = putc ( c , con->data );
  16.   return i;
  17. }
  18.