From 2555743c2b9d7408e8cf6f0fd1064651b37db08e Mon Sep 17 00:00:00 2001 From: Ian Lynagh Date: Thu, 14 Apr 2011 22:45:02 +0100 Subject: [PATCH] Check for ^M in packages file when booting If we find one then we print an error message and fail. --- boot | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/boot b/boot index 9d7eb38..66bff3e 100755 --- a/boot +++ b/boot @@ -24,6 +24,24 @@ while ($#ARGV ne -1) { } } +{ + local $/ = undef; + open FILE, "packages" or die "Couldn't open file: $!"; + binmode FILE; + my $string = ; + close FILE; + + if ($string =~ /\r/) { + print STDERR <