summaryrefslogtreecommitdiffstats
path: root/rescue
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2012-05-23 18:25:29 +0000
committerThierry Vignaud <tv@mageia.org>2012-05-23 18:25:29 +0000
commitedebda2f1b87e76cdbc7d50eef95d1a75360016d (patch)
tree2403b06be8881b3a6285e5753ec1de1578f8699c /rescue
parent0030eeeda19ceabdf141a16d2da971b4a51aaec7 (diff)
downloaddrakx-backup-do-not-use-edebda2f1b87e76cdbc7d50eef95d1a75360016d.tar
drakx-backup-do-not-use-edebda2f1b87e76cdbc7d50eef95d1a75360016d.tar.gz
drakx-backup-do-not-use-edebda2f1b87e76cdbc7d50eef95d1a75360016d.tar.bz2
drakx-backup-do-not-use-edebda2f1b87e76cdbc7d50eef95d1a75360016d.tar.xz
drakx-backup-do-not-use-edebda2f1b87e76cdbc7d50eef95d1a75360016d.zip
(cat_) sync with MDK::Common (but keep older error message)
(perl_checker cleanups)
Diffstat (limited to 'rescue')
-rwxr-xr-xrescue/tree/sbin/fakeshutdown3
1 files changed, 2 insertions, 1 deletions
diff --git a/rescue/tree/sbin/fakeshutdown b/rescue/tree/sbin/fakeshutdown
index cfc6df4dc..309f26c6c 100755
--- a/rescue/tree/sbin/fakeshutdown
+++ b/rescue/tree/sbin/fakeshutdown
@@ -13,7 +13,8 @@
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
-sub cat_ { local *F; open F, $_[0] or die "cat of file $_[0] failed: $!\n"; my @l = <F>; wantarray ? @l : join '', @l }
+# From MDK::Common:
+sub cat_ { open(my $F, '<', $_[0]) or die "cat of file $_[0] failed: $!\n"; my @l = <$F>; wantarray() ? @l : join '', @l }
print "\n";