home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fish 'n' More 1
/
FishNMoreVol1.bin
/
more
/
code_examples
/
librar
/
lfile2he.c
< prev
next >
Wrap
Text File
|
1989-02-08
|
529b
|
25 lines
/*--------------------------------------*/
/* */
/* LFILE2HEX(X) */
/* */
/* Reads and returns a number from a */
/* file. The argument is the file desc- */
/* riptor. */
/* */
/* Written by John Callicotte */
/* */
/*--------------------------------------*/
# include "stdio.h"
long lfile2hex(fd)
FILE *fd;
{
int a,b,c,d;
long e;
a=getc(fd);
b=getc(fd);
c=getc(fd);
d=getc(fd);
e=16777216L*a+65536L*b+256L*c+d;
return(e);
}