Continues NASM support. This might work now. Its still experimental but it
[openssl.git] / crypto / bio / b_dump.c
index 71bbce8ce180421ad2becf6e40e943b5a9e5417b..a7cd828978505ca1607cca7f84eb28a15466276f 100644 (file)
@@ -102,7 +102,13 @@ int BIO_dump(BIO *bio, const char *s, int len)
       if (((i*DUMP_WIDTH)+j)>=len)
        break;
       ch=((unsigned char)*((char *)(s)+i*DUMP_WIDTH+j)) & 0xff;
+#ifndef CHARSET_EBCDIC
       sprintf(tmp,"%c",((ch>=' ')&&(ch<='~'))?ch:'.');
+#else
+      sprintf(tmp,"%c",((ch>=os_toascii[' '])&&(ch<=os_toascii['~']))
+             ? os_toebcdic[ch]
+             : '.');
+#endif
       strcat(buf,tmp);
     }
     strcat(buf,"\n");