summaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
authorjerenkrantz <jerenkrantz@13f79535-47bb-0310-9956-ffa450edef68>2004-11-17 01:07:02 +0000
committerjerenkrantz <jerenkrantz@13f79535-47bb-0310-9956-ffa450edef68>2004-11-17 01:07:02 +0000
commit6c396ff5c726ad3ccba9f8454d1d41ab65513945 (patch)
tree9fe875f78a137b87968ce8d5bcf5b554f2608fab /misc
parent9ffc3ba97e22859b387d44eaf5d48e559c6e8874 (diff)
downloadlibapr-6c396ff5c726ad3ccba9f8454d1d41ab65513945.tar.gz
Merge in changes from trunk to 1.0.x.
Changes have been reviewed to be binary compatible with 1.0.0 by Justin to the best of his sleep-deprived ability. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/branches/1.0.x@76072 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'misc')
-rw-r--r--misc/unix/charset.c2
-rw-r--r--misc/unix/errorcodes.c8
2 files changed, 8 insertions, 2 deletions
diff --git a/misc/unix/charset.c b/misc/unix/charset.c
index 5e1842fac..6acb4e157 100644
--- a/misc/unix/charset.c
+++ b/misc/unix/charset.c
@@ -55,7 +55,7 @@ APR_DECLARE(const char*) apr_os_default_encoding (apr_pool_t *pool)
}
if ('A' == 0x41) {
- return "ISO8859-1"; /* not necessarily true */
+ return "ISO-8859-1"; /* not necessarily true */
}
return "unknown";
diff --git a/misc/unix/errorcodes.c b/misc/unix/errorcodes.c
index 447b8d859..5c318d530 100644
--- a/misc/unix/errorcodes.c
+++ b/misc/unix/errorcodes.c
@@ -374,7 +374,13 @@ static char *native_strerror(apr_status_t statcode, char *buf,
sprintf(err, "Native Error #%d", statcode);
return stuffbuffer(buf, bufsize, err);
#else
- return stuffbuffer(buf, bufsize, strerror(statcode));
+ const char *err = strerror(statcode);
+ if (err) {
+ return stuffbuffer(buf, bufsize, err);
+ } else {
+ return stuffbuffer(buf, bufsize,
+ "APR does not understand this error code");
+ }
#endif
}
#endif