libexplain  1.4.D001
Functions
libexplain/dirname.h File Reference
#include <libexplain/ac/stddef.h>

Go to the source code of this file.

Functions

void explain_dirname (char *dir, const char *path, size_t dir_size)
void explain_basename (char *filnam, const char *path, size_t filnam_size)

Function Documentation

void explain_basename ( char *  filnam,
const char *  path,
size_t  filnam_size 
)

The explain_basename function may be used to extract the final component of a path.

Parameters:
filnamThe array to receive the filename
pathThe path from which to extract the final component.
filnam_sizeThe size of the array to receive the file name

Definition at line 74 of file dirname.c.

void explain_dirname ( char *  dir,
const char *  path,
size_t  dir_size 
)

The explain_dirname function may be used to extract the directory part of a path.

Parameters:
dirThe array in which to place the directory part.
pathThe path from which to extract the directory part.
dir_sizeThe size in bytes of the destination dir array.

Definition at line 29 of file dirname.c.