18 lines
524 B
Diff
18 lines
524 B
Diff
commit 4c0060639f6fa854830a708a823976772afe7764
|
|
Author: Lukas Lansky <lukas.lansky@suse.com>
|
|
Date: Tue Mar 2 20:40:05 2021 +0100
|
|
|
|
Fixing possible resource leak. Found by running ccpcheck on the source code.
|
|
|
|
diff --git a/get_kernel_version.c b/get_kernel_version.c
|
|
index c042487..12e713a 100644
|
|
--- a/get_kernel_version.c
|
|
+++ b/get_kernel_version.c
|
|
@@ -84,6 +84,7 @@ main (int argc, char *argv[])
|
|
if (fp == NULL)
|
|
{
|
|
fprintf (stderr, "%s: faild\n", command);
|
|
+ close (fd);
|
|
return 1;
|
|
}
|
|
}
|