File: strerror.c

package info (click to toggle)
html-xml-utils 6.1-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 1,620 kB
  • sloc: ansic: 10,027; sh: 2,135; lex: 189; yacc: 125; perl: 123; makefile: 122
file content (21 lines) | stat: -rw-r--r-- 552 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
/*
 * Copyright  1994-2000 World Wide Web Consortium
 * See http://www.w3.org/Consortium/Legal/copyright-software
 *
 * Author: Bert Bos <bert@w3.org>
 * Created: 31 Mar 2000
 * Version: $Id: strerror.c,v 1.3 2007/10/23 11:17:08 bbos Exp $
 **/
#include <config.h>
#ifdef HAVE_ERRNO_H
#  include <errno.h>
#endif
#include "export.h"

#ifndef HAVE_STRERROR
/* strerror -- return a string describing the error number */
EXPORT char *strerror(int errnum)
{
  return errnum < sys_nerr ? sys_errlist[errnum] : "Unknown error";
}
#endif /* HAVE_STRERROR */