summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorNorbert Preining <preining@logic.at>2017-10-14 08:32:09 +0000
committerNorbert Preining <preining@logic.at>2017-10-14 08:32:09 +0000
commit5b212b8ee20d87ed0e687d3faa23f0f26d71d2c3 (patch)
tree34d1bac3e759bd74e57126c6513f07bf469fa1c7 /Master
parentf6339dc74cfb9ec8b3ed5e08a799aa7cc39b60a2 (diff)
fix undefined errors on checks
git-svn-id: svn://tug.org/texlive/trunk@45539 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rwxr-xr-xMaster/texmf-dist/scripts/texlive/tlmgr.pl10
1 files changed, 7 insertions, 3 deletions
diff --git a/Master/texmf-dist/scripts/texlive/tlmgr.pl b/Master/texmf-dist/scripts/texlive/tlmgr.pl
index 921cf70463c..7dd33fd6d0d 100755
--- a/Master/texmf-dist/scripts/texlive/tlmgr.pl
+++ b/Master/texmf-dist/scripts/texlive/tlmgr.pl
@@ -1412,7 +1412,7 @@ sub action_info {
my $ret = $F_OK | $F_NOPOSTACTION;
my @datafields;
my $fmt = "list";
- if ($opts{'data'} eq "json") {
+ if ($opts{'data'} && ($opts{'data'} eq "json")) {
eval { require JSON; };
if ($@) {
# that didn't work out, give some usefull error message and stop
@@ -1461,8 +1461,12 @@ Goodbye.
}
# we are still here, so $what is defined and neither collection nor scheme,
# so assume the arguments are package names
- if ($opts{'data'} ne "json") {
- $fmt = ($opts{'data'} ? "csv" : "detail");
+ if ($opts{'data'}) {
+ if ($opts{'data'} ne "json") {
+ $fmt = "csv";
+ }
+ } else {
+ $fmt = "detail";
}
my @adds;
if ($opts{'data'}) {