home *** CD-ROM | disk | FTP | other *** search
/ Stars of Shareware: Programmierung / SOURCE.mdf / programm / msdos / c / pictor15 / libsrc / computs.c < prev    next >
Encoding:
C/C++ Source or Header  |  1994-03-15  |  377 b   |  23 lines

  1. /*
  2. ** computs.c
  3. **
  4. ** Pictor, Version 1.51, Copyright (c) 1992-94 SoftCircuits
  5. ** Redistributed by permission.
  6. */
  7.  
  8. #include "comlib.h"
  9.  
  10. /*
  11. ** Writes a null-terminates string to the communications port.
  12. ** Returns 0 if successful, -1 if error.
  13. */
  14. int computs(char *str)
  15. {
  16.     while(*str) {
  17.         if(computc(*str++))
  18.             return(-1);
  19.     }
  20.     return(0);
  21.  
  22. } /* computs */
  23.