| iMatix home page | << | < | > | >> |
SFL Version 2.11 |
#include "sflfile.h" FILE * file_locate ( const char *path, const char *name, const char *ext)
Combines the functions of file where() and file_open when you want to read a file. Searches for a file on a specified path, opens the file if found, and returns a FILE * for the open file. Returns NULL if the file was not found or could not be opened for reading.
{ char *filename; ASSERT (name); filename = file where ('r', path, name, ext); if (filename) return (file open (filename, 'r')); else return (NULL); }
| << | < | > | >> | Copyright © 1996-2000 iMatix Corporation |