home *** CD-ROM | disk | FTP | other *** search
/ Fish 'n' More 1 / FishNMoreVol1.bin / more / code_examples / librar / sfile2he.c < prev    next >
Text File  |  1989-02-08  |  476b  |  22 lines

  1. /*--------------------------------------*/
  2. /*                    */
  3. /*            SFILE2HEX(X)        */
  4. /*                    */
  5. /* Reads and returns a number from a    */
  6. /* file. The argument is the file desc- */
  7. /* riptor.                */
  8. /*                    */
  9. /*      Written by John Callicotte    */
  10. /*                    */
  11. /*--------------------------------------*/
  12. # include "stdio.h"
  13. sfile2hex(fd)
  14. FILE *fd;
  15. {
  16.         int c,d,e;
  17.         c=scram(getc(fd));
  18.         d=scram(getc(fd));
  19.         e=256*c+d;
  20.         return(e);
  21. }
  22.