summaryrefslogtreecommitdiff
path: root/Build
diff options
context:
space:
mode:
authorAkira Kakuto <kakuto@fuk.kindai.ac.jp>2020-02-06 09:19:24 +0000
committerAkira Kakuto <kakuto@fuk.kindai.ac.jp>2020-02-06 09:19:24 +0000
commit573db774ae37e832d2146e2db48a085be89a4c1b (patch)
tree1901d4826ffcd6ae0b6d62c86fef7af487eb883f /Build
parent0d82fd6d67f9a1cf5e2af3873aec855effb4913c (diff)
remove unnecessary assert() check (from S. Hirata)
git-svn-id: svn://tug.org/texlive/trunk@53690 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build')
-rw-r--r--Build/source/texk/dvipdfm-x/ChangeLog9
-rw-r--r--Build/source/texk/dvipdfm-x/pdfobj.c10
2 files changed, 14 insertions, 5 deletions
diff --git a/Build/source/texk/dvipdfm-x/ChangeLog b/Build/source/texk/dvipdfm-x/ChangeLog
index db3de86ee15..395a88b458c 100644
--- a/Build/source/texk/dvipdfm-x/ChangeLog
+++ b/Build/source/texk/dvipdfm-x/ChangeLog
@@ -1,3 +1,12 @@
+2020-02-06 Shunsaku Hirata <shunsaku.hirata74@gmail.com>
+
+ * pdfobj.c: In pdf_new_string(), the supplied string was
+ checked and dvipdfmx aborted when it was NULL. This check
+ is removed since it is actually not necessary. The string is
+ regarded simply as an empty string if it is NULL from now on.
+ See https://tex.stackexchange.com/questions/522794/problem-in-updated-tex-live,
+ although we can't reproduce the problem.
+
2020-01-24 Akira Kakuto <kakuto@w32tex.org>
* dvi.c: Forgot to null-terminate strings in the previous
diff --git a/Build/source/texk/dvipdfm-x/pdfobj.c b/Build/source/texk/dvipdfm-x/pdfobj.c
index 50246fc7ede..fc977d2a06f 100644
--- a/Build/source/texk/dvipdfm-x/pdfobj.c
+++ b/Build/source/texk/dvipdfm-x/pdfobj.c
@@ -1,6 +1,6 @@
/* This is dvipdfmx, an eXtended version of dvipdfm by Mark A. Wicks.
- Copyright (C) 2007-2019 by Jin-Hwan Cho and Shunsaku Hirata,
+ Copyright (C) 2007-2020 by Jin-Hwan Cho and Shunsaku Hirata,
the dvipdfmx project team.
Copyright (C) 1998, 1999 by Mark A. Wicks <mwicks@kettering.edu>
@@ -938,20 +938,20 @@ pdf_new_string (const void *str, unsigned length)
pdf_obj *result;
pdf_string *data;
- ASSERT(str);
-
result = pdf_new_obj(PDF_STRING);
data = NEW(1, pdf_string);
result->data = data;
data->length = length;
- if (length) {
+ if (str && length > 0) {
data->string = NEW(length+1, unsigned char);
memcpy(data->string, str, length);
/* Shouldn't assume NULL terminated. */
data->string[length] = '\0';
- } else
+ } else {
data->string = NULL;
+ data->length = 0;
+ }
return result;
}