JWS C Library
C language utility library
|
Declarations for manipulating file and directory names. More...
#include <jwsc/config.h>
#include <stdlib.h>
#include <stdio.h>
Go to the source code of this file.
Functions | |
int | fname_has_suffix (const char *fname, const char *suffix) |
Returns whether a file name has a certain suffix. | |
char * | get_fname_suffix (const char *fname) |
Returns a copy of the file name suffix, if it has one. | |
char * | get_fname_dir (const char *fname) |
Returns a copy of the file name directory prefix. | |
char * | get_fname_base (const char *fname) |
Declarations for manipulating file and directory names.
Definition in file fname.h.
int fname_has_suffix | ( | const char * | fname, |
const char * | suffix | ||
) |
char* get_fname_suffix | ( | const char * | fname | ) |
char* get_fname_dir | ( | const char * | fname | ) |
Returns a copy of the file name directory prefix.
Directory is everything before the last '/' in the file name.
fname | File name to get the directory of. |