From f71ce341800739c7cdee01d7cf025e7492da22ac Mon Sep 17 00:00:00 2001 From: Guus Sliepen Date: Sun, 25 Mar 2012 15:17:50 +0100 Subject: [PATCH] Fix return type of vde_recv() as well. In this case it is not really necessary as the conversion to int will already take care of ensuring the return value is treated as signed. --- src/vde_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vde_device.c b/src/vde_device.c index 1f1d8cf8..e69ae802 100644 --- a/src/vde_device.c +++ b/src/vde_device.c @@ -99,7 +99,7 @@ static void close_device(void) { } static bool read_packet(vpn_packet_t *packet) { - int lenin = plug.vde_recv(conn, packet->data, MTU, 0); + int lenin = (ssize_t)plug.vde_recv(conn, packet->data, MTU, 0); if(lenin <= 0) { logger(LOG_ERR, "Error while reading from %s %s: %s", device_info, device, strerror(errno)); running = false; -- 2.39.5