home *** CD-ROM | disk | FTP | other *** search
/ Piper's Pit BBS/FTP: ibm 0020 - 0029 / ibm0020-0029 / ibm0028.tar / ibm0028 / GRLF-C-2.ZIP / GFUNC / FEXIST.C < prev    next >
Encoding:
C/C++ Source or Header  |  1990-05-30  |  532 b   |  33 lines

  1. /*
  2.  * fexist.c
  3.  * contains: fexist()
  4.  *
  5.  */
  6.  
  7. #include <stdio.h>
  8. #include "gfuncts.h"
  9.  
  10. /*
  11.  *  bool
  12.  * fexist(name)
  13.  *
  14.  * ARGUMENT
  15.  *  (char *)    name    -    file name to check.
  16.  *
  17.  * DESCRIPTION
  18.  *  See if a file exists using dosfirst() to search for the file.
  19.  *
  20.  * RETURNS
  21.  *  TRUE if file exists, else FALSE
  22.  *
  23.  * AUTHOR
  24.  *   Copyright (C)1987-1990 Greenleaf Software Inc. All Rights Reserved.
  25.  */
  26. bool GF_CONV fexist(name)
  27. char *name;
  28. {
  29.     char dest[40];
  30.  
  31.     return((dosfirst(name,0,dest)==0)?TRUE:FALSE);
  32. }
  33.