mirror of
https://git.proxmox.com/git/mirror_lxc
synced 2025-08-03 12:06:43 +00:00
p is a pointer and cannot be negative so check if it is NULL
Signed-off-by: S.Çağlar Onur <caglar@10ur.org> Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com>
This commit is contained in:
parent
d380c7ff55
commit
7be677a8aa
@ -483,7 +483,7 @@ int sha1sum_file(char *fnam, unsigned char *digest)
|
||||
process_lock();
|
||||
f = fopen_cloexec(fnam, "r");
|
||||
process_unlock();
|
||||
if (f < 0) {
|
||||
if (!f) {
|
||||
SYSERROR("Error opening template");
|
||||
return -1;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user