diff options
author | Norbert Preining <preining@logic.at> | 2008-08-01 09:59:00 +0000 |
---|---|---|
committer | Norbert Preining <preining@logic.at> | 2008-08-01 09:59:00 +0000 |
commit | 12d1d2189358571f6dad4c52b604ae438b8d250e (patch) | |
tree | f06c598553fea17cebc8c5cfbead76e80824cd72 /Master/tlpkg/TeXLive | |
parent | 4620a8397c0e31ef27df5471d8a9c25efa9a14f2 (diff) |
TLWinGoo: catch open errors with die
git-svn-id: svn://tug.org/texlive/trunk@9975 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/TeXLive')
-rw-r--r-- | Master/tlpkg/TeXLive/TLWinGoo.pm | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Master/tlpkg/TeXLive/TLWinGoo.pm b/Master/tlpkg/TeXLive/TLWinGoo.pm index fac1304e675..d41cb4b10bb 100644 --- a/Master/tlpkg/TeXLive/TLWinGoo.pm +++ b/Master/tlpkg/TeXLive/TLWinGoo.pm @@ -841,7 +841,8 @@ sub add_desktop_shortcut { $shc->Save($shfile); # update batchfile for uninstalling shortcuts - open UNSHORT, ">>$texdir/tlpkg/installer/unshort.bat"; + open UNSHORT, ">>$texdir/tlpkg/installer/unshort.bat" || + die "Cannot open $texdir/tlpkg/installer/unshort.bat for appending: $!"; $shfile =~ s!/!\\!g; print UNSHORT 'del "'.$shfile."\" 2>nul\n"; close UNSHORT; @@ -898,7 +899,8 @@ sub init_unshortbat { $menupath =~ s!/!\\!g; # batchfile for uninstalling shortcuts - open UNSHORT, ">$texdirw/tlpkg/installer/unshort.bat"; + open UNSHORT, ">$texdirw/tlpkg/installer/unshort.bat" || + die "Cannot create $texdirw/tlpkg/installer/unshort.bat: $!"; print UNSHORT 'rmdir /s /q "'.$menupath."\\TeX Live 2008\" 2>nul\n"; close UNSHORT; } |