mirror of
https://git.proxmox.com/git/mirror_lxc
synced 2025-08-03 10:18:02 +00:00
coverity: #1425869
do not unmap prematurely Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
This commit is contained in:
parent
de429548c4
commit
3ca108148b
@ -625,8 +625,8 @@ static bool cull_entries(int fd, char *name, char *net_type, char *net_link,
|
||||
}
|
||||
free(entry_lines);
|
||||
|
||||
lxc_strmunmap(buf, sb.st_size);
|
||||
ret = ftruncate(fd, buf_start - buf);
|
||||
lxc_strmunmap(buf, sb.st_size);
|
||||
if (ret < 0)
|
||||
usernic_error("Failed to set new file size: %s\n",
|
||||
strerror(errno));
|
||||
|
Loading…
Reference in New Issue
Block a user