diff options
author | Thanos Makatos <thanos.makatos@nutanix.com> | 2020-12-04 06:56:11 -0500 |
---|---|---|
committer | Thanos Makatos <tmakatos@gmail.com> | 2020-12-07 11:34:47 +0000 |
commit | da0d10c0d2235004254971d6789ea869b4b971ad (patch) | |
tree | 403300a790abb271541167755cbf9a38048ab4f9 | |
parent | b10591fe89dc570d3e099b192fa1dbd37204f474 (diff) | |
download | libvfio-user-da0d10c0d2235004254971d6789ea869b4b971ad.zip libvfio-user-da0d10c0d2235004254971d6789ea869b4b971ad.tar.gz libvfio-user-da0d10c0d2235004254971d6789ea869b4b971ad.tar.bz2 |
don't return invalid errno
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
-rw-r--r-- | lib/tran_sock.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/tran_sock.c b/lib/tran_sock.c index a9af65e..f96784d 100644 --- a/lib/tran_sock.c +++ b/lib/tran_sock.c @@ -107,7 +107,7 @@ init_sock(vfu_ctx_t *vfu_ctx) /* start listening business */ ret = bind(unix_sock, (struct sockaddr*)&addr, sizeof(addr)); if (ret < 0) { - ret = errno; + ret = -errno; goto out; } |