diff options
author | Andreas Baumann <abaumann@yahoo.com> | 2010-05-23 14:37:19 +0200 |
---|---|---|
committer | Andreas Baumann <abaumann@yahoo.com> | 2010-05-23 14:37:19 +0200 |
commit | 5998a2c035e90aa01d97da26b9ef2b2b503f3d83 (patch) | |
tree | 8d93a81c00b19be101b5bfdaeaa376a8578ab4b7 /src | |
parent | c3cdb4a066b7ba278015ea3e6e19fa4df2038faf (diff) | |
download | wolfbones-5998a2c035e90aa01d97da26b9ef2b2b503f3d83.tar.gz wolfbones-5998a2c035e90aa01d97da26b9ef2b2b503f3d83.tar.bz2 |
fixed error handling on Unix
Diffstat (limited to 'src')
-rw-r--r-- | src/errors.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/errors.c b/src/errors.c index a453dbe..9914b51 100644 --- a/src/errors.c +++ b/src/errors.c @@ -15,14 +15,17 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include "port/string.h" /* for strncpy, strerror_r */ #include "errors.h" #include "port/gettext.h" /* for localization */ -#include "port/string.h" /* for strncpy, strerror_r */ + #if defined _WIN32 #define WIN32_MEAN_AND_LEAN -#include <windows.h> +#include <windows.h> /* for GetLastError */ +#else +#include <errno.h> /* for errno */ #endif /* defined _WIN32 */ char *wolf_error_msg( const wolf_error_t error, char *buf, size_t buflen ) { |