From ead3792e2d57305d0777008c5073968c36ec7ba3 Mon Sep 17 00:00:00 2001 From: Akira Kakuto Date: Fri, 25 Sep 2015 04:49:33 +0000 Subject: texk/dvipdfm-x/dvipdfmx.c: Use strtoul for kpathsea_debug. git-svn-id: svn://tug.org/texlive/trunk@38456 c570f23f-e606-0410-a88d-b1316a301751 --- Build/source/texk/dvipdfm-x/ChangeLog | 11 +++-------- Build/source/texk/dvipdfm-x/dvipdfmx.c | 3 ++- 2 files changed, 5 insertions(+), 9 deletions(-) (limited to 'Build') 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 - - * 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 + + * dvipdfmx.c: Use strtoul for kpathsea_debug. 2015-08-25 Peter Breitenlohner 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; -- cgit v1.2.3