Skip to content

Commit 075d5d3

Browse files
anhubammahadevan108
authored andcommitted
net: mqtt: Fix missing close function
If POSIX_API is not configured the close function is not available. Use zsock_close instead. Signed-off-by: Andreas Huber <andreas.huber@ch.sauter-bc.com>
1 parent fad8a1f commit 075d5d3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

subsys/net/lib/mqtt/mqtt_transport_websocket.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ int mqtt_client_websocket_connect(struct mqtt_client *client)
7777
NET_ERR("Websocket connect failed (%d)",
7878
client->transport.websocket.sock);
7979

80-
(void)close(transport_sock);
80+
(void)zsock_close(transport_sock);
8181
return client->transport.websocket.sock;
8282
}
8383

0 commit comments

Comments
 (0)