summaryrefslogtreecommitdiff
path: root/Build
diff options
context:
space:
mode:
authorHironobu Yamashita <h.y.acetaminophen@gmail.com>2019-05-22 14:38:18 +0000
committerHironobu Yamashita <h.y.acetaminophen@gmail.com>2019-05-22 14:38:18 +0000
commit109c4d8e7b494b81121f90f487913ac6af3bbf99 (patch)
tree8086e27bfc37ad9a6b55a20d16c5d1341411e210 /Build
parent95489e10e75c9789ffd4a9237209f3a9c1dba552 (diff)
bibtexu: debug code
git-svn-id: svn://tug.org/texlive/trunk@51188 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build')
-rw-r--r--Build/source/texk/bibtex-x/ChangeLog1
-rw-r--r--Build/source/texk/bibtex-x/bibtex-2.c19
-rw-r--r--Build/source/texk/bibtex-x/bibtex-3.c4
3 files changed, 13 insertions, 11 deletions
diff --git a/Build/source/texk/bibtex-x/ChangeLog b/Build/source/texk/bibtex-x/ChangeLog
index 7010e710cdc..2f33776fe14 100644
--- a/Build/source/texk/bibtex-x/ChangeLog
+++ b/Build/source/texk/bibtex-x/ChangeLog
@@ -1,5 +1,6 @@
2019-05-22 Hironobu Yamashita <h.y.acetaminophen@gmail.com>
+ * bibtex-2.c, bibtex-3.c: Better error messages for debug.
* bibtex-3.c (icu_strToUpper): React to Str_language.
2019-05-05 Hironobu Yamashita <h.y.acetaminophen@gmail.com>
diff --git a/Build/source/texk/bibtex-x/bibtex-2.c b/Build/source/texk/bibtex-x/bibtex-2.c
index 2fad5ab2dfc..d863b6fec3a 100644
--- a/Build/source/texk/bibtex-x/bibtex-2.c
+++ b/Build/source/texk/bibtex-x/bibtex-2.c
@@ -2973,16 +2973,17 @@ If err1 != U_ZERO_ERROR, the original functions are used. (06/mar/2019)
uchlen1 = icu_toUChars(entry_strs, (ptr1 * (ENT_STR_SIZE+1)), lenk1, uch1, ucap);
uchlen2 = icu_toUChars(entry_strs, (ptr2 * (ENT_STR_SIZE+1)), lenk2, uch2, ucap);
*/
- u_strFromUTF8WithSub(uch1, ucap, &uchlen1, (char *)&ENTRY_STRS(ptr1, 0), lenk1, 0xfffd, NULL, &err1);
+ u_strFromUTF8WithSub(uch1, ucap, &uchlen1, (char *)&ENTRY_STRS(ptr1, 0), lenk1, 0xfffd, NULL, &err1);
if (!U_SUCCESS(err1)) {
+ printf("Error in u_strFromUTF8WithSub 1.\n");
uchlen1 = icu_toUChars(entry_strs, (ptr1 * (ENT_STR_SIZE+1)), lenk1, uch1, ucap);
err1 = U_ZERO_ERROR;
}
u_strFromUTF8WithSub(uch2, ucap, &uchlen2, (char *)&ENTRY_STRS(ptr2, 0), lenk2, 0xfffd, NULL, &err1);
-
if (!U_SUCCESS(err1)) {
+ printf("Error in u_strFromUTF8WithSub 2.\n");
uchlen2 = icu_toUChars(entry_strs, (ptr2 * (ENT_STR_SIZE+1)), lenk2, uch2, ucap);
err1 = U_ZERO_ERROR;
}
@@ -2992,7 +2993,7 @@ If err1 != U_ZERO_ERROR, the original functions are used. (06/mar/2019)
else
ucol1 = ucol_open(NULL, &err1);
if (!U_SUCCESS(err1))
- printf("there is a error: U_ZERO_ERROR, open a ucol.");
+ printf("Error in opening a ucol in less_than.\n");
u_less = !ucol_greaterOrEqual(ucol1, uch1, uchlen1, uch2, uchlen2);
#ifdef TRACE
if (Flag_trace)
@@ -3156,12 +3157,12 @@ BEGIN
ucon1 = ucnv_open(NULL, &err1);
if (!U_SUCCESS(err1))
BEGIN
- printf("1there is a error: U_ZERO_ERROR");
+ printf("Error in opening a ucnv in icu_toUChars.\n");
END
ucnv_toUChars(ucon1, target, tarcap, (char *)&buf[bf_ptr], len, &err1);
if (!U_SUCCESS(err1))
BEGIN
- printf("2there is a error: U_ZERO_ERROR");
+ printf("Error in icu_toUChars.\n");
END
ucnv_close(ucon1);
@@ -3177,7 +3178,7 @@ BEGIN
UErrorCode err1 = U_ZERO_ERROR;
if (!U_SUCCESS(err1))
BEGIN
- printf("3there is a error: U_ZERO_ERROR");
+ printf("Error in icu_strToLower?\n");
END
if (Flag_language)
{
@@ -3190,7 +3191,7 @@ BEGIN
if (!U_SUCCESS(err1))
BEGIN
int16_t i=0;
- printf("4there is a error: U_ZERO_ERROR");
+ printf("Error in icu_strToLower.\n");
for (i=0;i<tarlen;i++)
BEGIN
printf("%X", target[i]);
@@ -3218,12 +3219,12 @@ BEGIN
ucon2 = ucnv_open(NULL, &err2);
if (!U_SUCCESS(err2))
BEGIN
- printf("5there is a error: U_ZERO_ERROR");
+ printf("Error in opening a ucnv in icu_fromUChars.\n");
END
tblen=ucnv_fromUChars(ucon2, (char *)dest, destcap, src, srclen, &err2);
if (!U_SUCCESS(err2))
BEGIN
- printf("6there is a error: U_ZERO_ERROR");
+ printf("Error in icu_fromUChars.\n");
END
return tblen;
diff --git a/Build/source/texk/bibtex-x/bibtex-3.c b/Build/source/texk/bibtex-x/bibtex-3.c
index f6ffeffe474..aa25d1021f9 100644
--- a/Build/source/texk/bibtex-x/bibtex-3.c
+++ b/Build/source/texk/bibtex-x/bibtex-3.c
@@ -3143,7 +3143,7 @@ BEGIN
UErrorCode err1 = U_ZERO_ERROR;
if (!U_SUCCESS(err1))
BEGIN
- printf("3there is a error: U_ZERO_ERROR");
+ printf("Error in icu_strToUpper?\n");
END
if (Flag_language)
{
@@ -3155,7 +3155,7 @@ BEGIN
}
if (!U_SUCCESS(err1))
BEGIN
- printf("4there is a error: U_ZERO_ERROR");
+ printf("Error in icu_strToUpper.\n");
END
return tulen;