core: add missing oom check

Fixes #17552.
This commit is contained in:
Yu Watanabe
2020-11-10 09:22:43 +01:00
committed by Zbigniew Jędrzejewski-Szmek
parent d61db498bf
commit 72585a584d
+2
View File
@@ -1710,6 +1710,8 @@ static int socket_open_fds(Socket *_s) {
_cleanup_free_ char *ep = NULL;
ep = path_make_absolute("ep0", p->path);
if (!ep)
return -ENOMEM;
p->fd = usbffs_address_create(ep);
if (p->fd < 0)