libexplain  1.4.D001
Functions
libexplain/reverse_strerror.h File Reference

Go to the source code of this file.

Functions

int explain_reverse_strerror (const char *text)

Function Documentation

int explain_reverse_strerror ( const char *  text)

The explain_reverse_strerror function may be used to translate the text of an error returned by strerror back into an errno value. Given that useres frequently mangle the text when they are reporting error messages, this can be tricky.

Parameters:
textThe text of the error message.
Returns:
an errno value, or -1 if there is nothing remotely similar

Definition at line 25 of file reverse_strerror.c.