Messages in this thread Patch in this message | | | Date | Fri, 02 May 2008 12:20:53 -0500 | From | Eric Sandeen <> | Subject | [PATCH] fix checkstack.pl arch detection |
| |
uname -m was leaving a newline in $arch, and not passing the tests.
Also, printing the unknown arch on failure is probably helpful.
Signed-off-by: Eric Sandeen <sandeen@redhat.com> ---
Index: linux-2.6.25/scripts/checkstack.pl =================================================================== --- linux-2.6.25.orig/scripts/checkstack.pl 2008-05-02 12:17:59.000000000 -0500 +++ linux-2.6.25/scripts/checkstack.pl 2008-05-02 12:18:15.426407528 -0500 @@ -32,6 +32,7 @@ my (@stack, $re, $x, $xs); my $arch = shift; if ($arch eq "") { $arch = `uname -m`; + chomp($arch); } $x = "[0-9a-f]"; # hex character @@ -85,7 +86,7 @@ my (@stack, $re, $x, $xs); # 0: 00 e8 38 01 LINK 0x4e0; $re = qr/.*[[:space:]]LINK[[:space:]]*(0x$x{1,8})/o; } else { - print("wrong or unknown architecture\n"); + print("wrong or unknown architecture \"$arch\"\n"); exit } }
| |