libubus: mark ubus socket with close-on-exec
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
This commit is contained in:
parent
f688c7ad0b
commit
b79e808944
1 changed files with 1 additions and 1 deletions
|
@ -379,7 +379,7 @@ int ubus_reconnect(struct ubus_context *ctx, const char *path)
|
|||
goto out_free;
|
||||
|
||||
ret = UBUS_STATUS_OK;
|
||||
fcntl(ctx->sock.fd, F_SETFL, fcntl(ctx->sock.fd, F_GETFL) | O_NONBLOCK);
|
||||
fcntl(ctx->sock.fd, F_SETFL, fcntl(ctx->sock.fd, F_GETFL) | O_NONBLOCK | O_CLOEXEC);
|
||||
|
||||
ubus_refresh_state(ctx);
|
||||
|
||||
|
|
Loading…
Reference in a new issue