libexplain  1.4.D001
Functions
libexplain/buffer/enotdir.h File Reference
#include <libexplain/string_buffer.h>

Go to the source code of this file.

Functions

void explain_buffer_enotdir (explain_string_buffer_t *sb, const char *pathname, const char *pathname_caption, const struct explain_final_t *pathname_final_component)
void explain_buffer_enotdir2 (explain_string_buffer_t *sb, const char *oldpath, const char *oldpath_caption, const struct explain_final_t *oldpath_final_component, const char *newpath, const char *newpath_caption, const struct explain_final_t *newpath_final_component)
void explain_buffer_enotdir_fd (explain_string_buffer_t *sb, int fildes, const char *fildes_caption)
int explain_fildes_is_a_directory (int fildes)

Function Documentation

void explain_buffer_enotdir ( explain_string_buffer_t sb,
const char *  pathname,
const char *  pathname_caption,
const struct explain_final_t pathname_final_component 
)

The explain_buffer_enotdir function may be used to

Parameters:
sbThe string buffer to print into
pathnameThe offending path
pathname_captionThe name of the function argument of the offending path
pathname_final_componentThe required properties of the final component of the offending path
void explain_buffer_enotdir2 ( explain_string_buffer_t sb,
const char *  oldpath,
const char *  oldpath_caption,
const struct explain_final_t oldpath_final_component,
const char *  newpath,
const char *  newpath_caption,
const struct explain_final_t newpath_final_component 
)

The explain_buffer_enotdir function may be used to

Parameters:
sbThe string buffer to print into
oldpathThe offending path
oldpath_captionThe name of the function argument of the offending path
oldpath_final_componentThe required properties of the final component of the offending path
newpathThe offending path
newpath_captionThe name of the function argument of the offending path
newpath_final_componentThe required properties of the final component of the offending path
void explain_buffer_enotdir_fd ( explain_string_buffer_t sb,
int  fildes,
const char *  fildes_caption 
)

The explain_buffer_enotdir_fd function may be used to

Parameters:
sbThe string buffer to print into
fildesThe offending file descriptor
fildes_captionThe name of the function argument of the offending file descriptor

Definition at line 139 of file enotdir.c.

int explain_fildes_is_a_directory ( int  fildes)

The explain_fildes_is_a_directory function is used to determine whether or not a file descriptor refers to a directory.

Parameters:
fildesThe file descriptor to be tested.
Returns:
true (nonzero0 if it is a dir; false (zero) is it is not a dir.

Definition at line 147 of file enotdir.c.