summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2016-04-06 16:06:48 +0300
committerDavid Howells <dhowells@redhat.com>2016-04-06 16:06:48 +0300
commit952cca6a724c420a1efb6025e41862dfd2c1edc3 (patch)
tree8782bbeea503ec01d2e2f2e970fb2e69a0eba8d3 /scripts
parent8d4a2ec1e0b41b0cf9a0c5cd4511da7f8e4f3de2 (diff)
downloadlinux-952cca6a724c420a1efb6025e41862dfd2c1edc3.tar.xz
ASN.1: fix open failure check on headername
The check for a failed open on headername is incorrectly checking on the out FILE pointer rather than the hdr. Fix this. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/asn1_compiler.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/asn1_compiler.c b/scripts/asn1_compiler.c
index e000f44e37b8..c1b7ef3e24c1 100644
--- a/scripts/asn1_compiler.c
+++ b/scripts/asn1_compiler.c
@@ -650,7 +650,7 @@ int main(int argc, char **argv)
}
hdr = fopen(headername, "w");
- if (!out) {
+ if (!hdr) {
perror(headername);
exit(1);
}