Commit 916492b1 authored by Chun-Yi Lee's avatar Chun-Yi Lee Committed by Linus Torvalds

sign-file: fix the perl warning message when extracting ASN.1

There have the following warning message when running modules install
for sign ko files:

  # make modules_install
  ...
    INSTALL drivers/input/touchscreen/pcap_ts.ko
  Found = in conditional, should be == at scripts/sign-file line 164.
  Found = in conditional, should be == at scripts/sign-file line 161.
  Found = in conditional, should be == at scripts/sign-file line 159.

This patch change replace '=' by '==' in elsif conditions for avoid the
above warning messages.
Signed-off-by: default avatarChun-Yi Lee <jlee@suse.com>
Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 99b6e1e7
...@@ -156,12 +156,12 @@ sub asn1_extract($$@) ...@@ -156,12 +156,12 @@ sub asn1_extract($$@)
if ($l == 0x1) { if ($l == 0x1) {
$len = unpack("C", substr(${$cursor->[2]}, $cursor->[0], 1)); $len = unpack("C", substr(${$cursor->[2]}, $cursor->[0], 1));
} elsif ($l = 0x2) { } elsif ($l == 0x2) {
$len = unpack("n", substr(${$cursor->[2]}, $cursor->[0], 2)); $len = unpack("n", substr(${$cursor->[2]}, $cursor->[0], 2));
} elsif ($l = 0x3) { } elsif ($l == 0x3) {
$len = unpack("C", substr(${$cursor->[2]}, $cursor->[0], 1)) << 16; $len = unpack("C", substr(${$cursor->[2]}, $cursor->[0], 1)) << 16;
$len = unpack("n", substr(${$cursor->[2]}, $cursor->[0] + 1, 2)); $len = unpack("n", substr(${$cursor->[2]}, $cursor->[0] + 1, 2));
} elsif ($l = 0x4) { } elsif ($l == 0x4) {
$len = unpack("N", substr(${$cursor->[2]}, $cursor->[0], 4)); $len = unpack("N", substr(${$cursor->[2]}, $cursor->[0], 4));
} else { } else {
die $x509, ": ", $cursor->[0], ": ASN.1 element too long (", $l, ")\n"; die $x509, ": ", $cursor->[0], ": ASN.1 element too long (", $l, ")\n";
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment