summaryrefslogtreecommitdiff
path: root/support/htdigest.c
diff options
context:
space:
mode:
authorJeff Trawick <trawick@apache.org>2000-12-20 16:44:01 +0000
committerJeff Trawick <trawick@apache.org>2000-12-20 16:44:01 +0000
commit351725e7266964eea4a0de39b6492fe5dfddf12d (patch)
treed47b145d0c624f40f21e2d78885823ff3ca1acd9 /support/htdigest.c
parentefe5ac62bd9c90d5b8f7f8694b581cfa21c9c818 (diff)
downloadhttpd-351725e7266964eea4a0de39b6492fe5dfddf12d.tar.gz
Switch to the APR-provided APR_CHARSET_EBCDIC feature test macro.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87460 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'support/htdigest.c')
-rw-r--r--support/htdigest.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/support/htdigest.c b/support/htdigest.c
index 9ed7dbacf8..e5f2384da0 100644
--- a/support/htdigest.c
+++ b/support/htdigest.c
@@ -92,23 +92,19 @@
#include <conio.h>
#endif
-#if 'A' == 0xC1
-#define AP_CHARSET_EBCDIC
-#endif
-
-#ifdef AP_CHARSET_EBCDIC
+#if APR_CHARSET_EBCDIC
#define LF '\n'
#define CR '\r'
#else
#define LF 10
#define CR 13
-#endif /* AP_CHARSET_EBCDIC */
+#endif /* APR_CHARSET_EBCDIC */
#define MAX_STRING_LEN 256
char *tn;
apr_pool_t *cntxt;
-#ifdef AP_CHARSET_EBCDIC
+#if APR_CHARSET_EBCDIC
apr_xlate_t *to_ascii;
#endif
@@ -192,7 +188,7 @@ static void add_password(char *user, char *realm, apr_file_t *f)
sprintf(string, "%s:%s:%s", user, realm, pw);
apr_MD5Init(&context);
-#ifdef AP_CHARSET_EBCDIC
+#if APR_CHARSET_EBCDIC
apr_MD5SetXlate(&context, to_ascii);
#endif
apr_MD5Update(&context, (unsigned char *) string, strlen(string));
@@ -241,7 +237,7 @@ int main(int argc, char *argv[])
atexit(apr_terminate);
apr_create_pool(&cntxt, NULL);
-#ifdef AP_CHARSET_EBCDIC
+#if APR_CHARSET_EBCDIC
rv = apr_xlate_open(&to_ascii, "ISO8859-1", APR_DEFAULT_CHARSET, cntxt);
if (rv) {
fprintf(stderr, "apr_xlate_open(): %s (%d)\n",