summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAkira Kakuto <kakuto@fuk.kindai.ac.jp>2015-09-25 04:49:33 +0000
committerAkira Kakuto <kakuto@fuk.kindai.ac.jp>2015-09-25 04:49:33 +0000
commitead3792e2d57305d0777008c5073968c36ec7ba3 (patch)
treeb512680dfa8982b3b4adf56f1f3d17c99a842a33
parent6c5342115a765fc2b9d6c1bb8984a065992c208d (diff)
texk/dvipdfm-x/dvipdfmx.c: Use strtoul for kpathsea_debug.
git-svn-id: svn://tug.org/texlive/trunk@38456 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Build/source/texk/dvipdfm-x/ChangeLog11
-rw-r--r--Build/source/texk/dvipdfm-x/dvipdfmx.c3
2 files changed, 5 insertions, 9 deletions
diff --git a/Build/source/texk/dvipdfm-x/ChangeLog b/Build/source/texk/dvipdfm-x/ChangeLog
index dfc9829077f..ab69196ab9b 100644
--- a/Build/source/texk/dvipdfm-x/ChangeLog
+++ b/Build/source/texk/dvipdfm-x/ChangeLog
@@ -1,11 +1,6 @@
-2015-09-24 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
-
- * dvipdfmx.c: Cast as kpathsea_debug = (uint32_t)atoi(optarg).
- Since kpathsea_debug is unsigned int, the cast must be redundant.
- However, a debian person says that he has:
- $ dvipdfmx --kpathsea-debug -1 test.dvi
- dvipdfmx:fatal: Invalid kpathsearch debugging flags specified: -1
- I cannot reproduce the behavior, but I add the redundant cast.
+2015-09-25 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
+
+ * dvipdfmx.c: Use strtoul for kpathsea_debug.
2015-08-25 Peter Breitenlohner <peb@mppmu.mpg.de>
diff --git a/Build/source/texk/dvipdfm-x/dvipdfmx.c b/Build/source/texk/dvipdfm-x/dvipdfmx.c
index b4ae449cc3e..e1f890c9661 100644
--- a/Build/source/texk/dvipdfm-x/dvipdfmx.c
+++ b/Build/source/texk/dvipdfm-x/dvipdfmx.c
@@ -461,7 +461,8 @@ do_args (int argc, char *argv[], const char *source)
break;
case 133: /* --kpathsea-debug */
- if ((kpathsea_debug = (uint32_t)atoi(optarg)) < 0)
+ kpathsea_debug = (unsigned) strtoul(optarg, &nextptr, 0);
+ if (nextptr == optarg)
ERROR("Invalid kpathsearch debugging flags specified: %s", optarg);
break;