diff --git a/src/lib3270/ansi.c b/src/lib3270/ansi.c index ab48269..5d81578 100644 --- a/src/lib3270/ansi.c +++ b/src/lib3270/ansi.c @@ -53,7 +53,7 @@ #include "hostc.h" #include "screenc.h" // #include "scrollc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "trace_dsc.h" #include "utf8c.h" @@ -1045,6 +1045,7 @@ ansi_printing(H3270 *hSession, int ig1 unused, int ig2 unused) Boolean preserve_right = False; #endif /*]*/ +/* if ((hSession->pmi == 0) && (hSession->ansi_ch & 0x80)) { char mbs[2]; enum ulfail fail; @@ -1052,27 +1053,29 @@ ansi_printing(H3270 *hSession, int ig1 unused, int ig2 unused) mbs[0] = (char)hSession->ansi_ch; mbs[1] = '\0'; + ch = utf8_lookup(mbs, &fail, NULL); if (ch == 0) { switch (fail) { case ULFAIL_NOUTF8: - /* Leave it alone. */ + // Leave it alone. break; case ULFAIL_INCOMPLETE: - /* Start munching multi-byte. */ + // Start munching multi-byte. hSession->pmi = 0; hSession->pending_mbs[hSession->pmi++] = (char)hSession->ansi_ch; return MBPEND; case ULFAIL_INVALID: - /* Invalid multi-byte -> '?' */ + // Invalid multi-byte -> '?' hSession->ansi_ch = '?'; - /* XXX: If DBCS, we should let - * ICU have a crack at it - */ + // XXX: If DBCS, we should let + // ICU have a crack at it + // break; } } } + */ hSession->pmi = 0; if (hSession->held_wrap) @@ -1216,7 +1219,7 @@ ansi_multibyte(H3270 *hSession, int ig1, int ig2) { char mbs[MB_MAX]; unsigned char ch; - enum ulfail fail; +// enum ulfail fail; afn_t fn; if (hSession->pmi >= MB_MAX - 2) @@ -1231,6 +1234,7 @@ ansi_multibyte(H3270 *hSession, int ig1, int ig2) mbs[hSession->pmi] = (char) hSession->ansi_ch; mbs[hSession->pmi + 1] = '\0'; + /* ch = utf8_lookup(mbs, &fail, NULL); if (ch != 0) { @@ -1245,6 +1249,7 @@ ansi_multibyte(H3270 *hSession, int ig1, int ig2) hSession->pending_mbs[hSession->pmi++] = (char)hSession->ansi_ch; return MBPEND; } + */ /* Failure. */ diff --git a/src/lib3270/charset.c b/src/lib3270/charset.c index b87b0af..87ea8d3 100644 --- a/src/lib3270/charset.c +++ b/src/lib3270/charset.c @@ -213,6 +213,9 @@ LIB3270_EXPORT struct lib3270_charset * lib3270_load_charset(H3270 *hSession, co hSession->charset.host = "bracket"; hSession->charset.display = "ISO-8859-1"; + lib3270_write_log(hSession,"charset","host.charset=%s display.charset=%s", + hSession->charset.host,hSession->charset.display); + memcpy(hSession->charset.ebc2asc, ebc2asc0, sizeof(hSession->charset.ebc2asc)); memcpy(hSession->charset.asc2ebc, asc2ebc0, sizeof(hSession->charset.asc2ebc)); diff --git a/src/lib3270/charset.h b/src/lib3270/charset.h index d3b49f1..bfe5d42 100644 --- a/src/lib3270/charset.h +++ b/src/lib3270/charset.h @@ -33,6 +33,9 @@ #define LIB3270_CHARSET_H_INCLUDED 1 + LIB3270_INTERNAL const unsigned short ebc2asc0[256]; + LIB3270_INTERNAL const unsigned short asc2ft0[256]; + const struct lib3270_charset lib3270_default_charset; LIB3270_EXPORT struct lib3270_charset * lib3270_load_charset(H3270 *hSession, const char *name); diff --git a/src/lib3270/ctlr.c b/src/lib3270/ctlr.c index d0dd7f0..99a11cb 100644 --- a/src/lib3270/ctlr.c +++ b/src/lib3270/ctlr.c @@ -57,7 +57,7 @@ #include "seec.h" #include "sf.h" #include "statusc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "trace_dsc.h" #include "utilc.h" diff --git a/src/lib3270/ft.c b/src/lib3270/ft.c index 8b2270c..43ccf70 100644 --- a/src/lib3270/ft.c +++ b/src/lib3270/ft.c @@ -48,7 +48,7 @@ #include "kybdc.h" #include "popupsc.h" #include "screenc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "utilc.h" #include "trace_dsc.h" diff --git a/src/lib3270/ft_cut.c b/src/lib3270/ft_cut.c index a7f44c5..d03cf9d 100644 --- a/src/lib3270/ft_cut.c +++ b/src/lib3270/ft_cut.c @@ -49,7 +49,7 @@ #include "ftc.h" #include "kybdc.h" #include "popupsc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "trace_dsc.h" #include "utilc.h" diff --git a/src/lib3270/ft_dft.c b/src/lib3270/ft_dft.c index 08e1dbb..5d02a05 100644 --- a/src/lib3270/ft_dft.c +++ b/src/lib3270/ft_dft.c @@ -49,7 +49,7 @@ #include "kybdc.h" #include "ft_dftc.h" #include "ftc.h" -#include "tablesc.h" +//#include "tablesc.h" #include "telnetc.h" #include "trace_dsc.h" #include "utilc.h" diff --git a/src/lib3270/glue.c b/src/lib3270/glue.c index 00f9592..27c04e9 100644 --- a/src/lib3270/glue.c +++ b/src/lib3270/glue.c @@ -65,7 +65,7 @@ #include "popupsc.h" #include "screenc.h" // #include "selectc.h" -#include "tablesc.h" +//#include "tablesc.h" #include "telnetc.h" #include "togglesc.h" #include "trace_dsc.h" diff --git a/src/lib3270/kybd.c b/src/lib3270/kybd.c index 39ca93c..9e8caa1 100644 --- a/src/lib3270/kybd.c +++ b/src/lib3270/kybd.c @@ -76,7 +76,7 @@ struct ta; // #include "selectc.h" // #endif /*]*/ #include "statusc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "togglesc.h" #include "trace_dsc.h" diff --git a/src/lib3270/paste.c b/src/lib3270/paste.c index 2c79b1f..512a008 100644 --- a/src/lib3270/paste.c +++ b/src/lib3270/paste.c @@ -68,7 +68,7 @@ */ #include "statusc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "togglesc.h" #include "trace_dsc.h" diff --git a/src/lib3270/rpq.c b/src/lib3270/rpq.c index 6282347..24c446a 100644 --- a/src/lib3270/rpq.c +++ b/src/lib3270/rpq.c @@ -59,7 +59,7 @@ #include "3270ds.h" #include "popupsc.h" -#include "tablesc.h" +//#include "tablesc.h" #include "telnetc.h" #include "trace_dsc.h" #include "utilc.h" diff --git a/src/lib3270/screen.c b/src/lib3270/screen.c index 40bcb47..06187bd 100644 --- a/src/lib3270/screen.c +++ b/src/lib3270/screen.c @@ -47,7 +47,7 @@ #include "hostc.h" #include "kybdc.h" #include "screenc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "trace_dsc.h" #include "utilc.h" // #include "w3miscc.h" diff --git a/src/lib3270/see.c b/src/lib3270/see.c index f05fd7e..2749eb1 100644 --- a/src/lib3270/see.c +++ b/src/lib3270/see.c @@ -46,7 +46,7 @@ #include #include "3270ds.h" -#include "tablesc.h" +// #include "tablesc.h" #if !defined(PR3287) /*[*/ #include "utf8c.h" #endif /*]*/ diff --git a/src/lib3270/session.c b/src/lib3270/session.c index 9eb702f..f492d45 100644 --- a/src/lib3270/session.c +++ b/src/lib3270/session.c @@ -44,7 +44,7 @@ #include "ftc.h" #include "kybdc.h" #include "3270ds.h" -#include "tablesc.h" +// #include "tablesc.h" #include "popupsc.h" #include "charset.h" diff --git a/src/lib3270/sf.c b/src/lib3270/sf.c index 4cf26dc..c0cac54 100644 --- a/src/lib3270/sf.c +++ b/src/lib3270/sf.c @@ -58,7 +58,7 @@ #include "screenc.h" #include "seec.h" #include "sf.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "trace_dsc.h" #include "utilc.h" diff --git a/src/lib3270/sources.mak b/src/lib3270/sources.mak index 1f9ce6b..f8108d9 100644 --- a/src/lib3270/sources.mak +++ b/src/lib3270/sources.mak @@ -26,10 +26,12 @@ # Terminal only sources TERMINAL_SOURCES = bounds.c ctlr.c util.c toggles.c screen.c selection.c kybd.c telnet.c \ - host.c sf.c ansi.c resolver.c tables.c utf8.c charset.c \ + host.c sf.c ansi.c resolver.c charset.c \ version.c session.c state.c html.c trace_ds.c see.c \ paste.c +# tables.c utf8.c + # Network I/O Sources NETWORK_SOURCES = iocalls.c proxy.c diff --git a/src/lib3270/tablesc.h b/src/lib3270/tablesc.h index 05beccd..eed07cd 100644 --- a/src/lib3270/tablesc.h +++ b/src/lib3270/tablesc.h @@ -16,8 +16,11 @@ * tablesc.h * Global declarations for tables.c. */ -LIB3270_INTERNAL void initialize_tables(H3270 *hSession); -LIB3270_INTERNAL void charset_defaults(H3270 *hSession); + +#error Deprecated, replace for charset.h + +// LIB3270_INTERNAL void initialize_tables(H3270 *hSession); +// LIB3270_INTERNAL void charset_defaults(H3270 *hSession); // LIB3270_INTERNAL unsigned short ebc2cg[256]; // LIB3270_INTERNAL unsigned short cg2ebc[256]; @@ -36,9 +39,7 @@ LIB3270_INTERNAL void charset_defaults(H3270 *hSession); // LIB3270_INTERNAL const unsigned short cg2asc[256]; // LIB3270_INTERNAL const unsigned short ebc2cg0[256]; // LIB3270_INTERNAL const unsigned short cg2ebc0[256]; - LIB3270_INTERNAL const unsigned short ebc2asc0[256]; // LIB3270_INTERNAL const unsigned short asc2ebc0[256]; // LIB3270_INTERNAL const unsigned short asc2uc[256]; // LIB3270_INTERNAL const unsigned short ebc2uc[256]; // LIB3270_INTERNAL const unsigned short ft2asc0[256]; - LIB3270_INTERNAL const unsigned short asc2ft0[256]; diff --git a/src/lib3270/telnet.c b/src/lib3270/telnet.c index c38a361..c838a4b 100644 --- a/src/lib3270/telnet.c +++ b/src/lib3270/telnet.c @@ -93,7 +93,7 @@ #include "proxyc.h" #include "resolverc.h" #include "statusc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "trace_dsc.h" #include "utilc.h" diff --git a/src/lib3270/trace_ds.c b/src/lib3270/trace_ds.c index f44d58b..c7b8fc3 100644 --- a/src/lib3270/trace_ds.c +++ b/src/lib3270/trace_ds.c @@ -59,7 +59,7 @@ // #include "charsetc.h" #include "ctlrc.h" #include "popupsc.h" -#include "tablesc.h" +// #include "tablesc.h" #include "telnetc.h" #include "trace_dsc.h" #include "utilc.h" -- libgit2 0.21.2