summaryrefslogtreecommitdiff
path: root/io
diff options
context:
space:
mode:
authorDaniel P. Berrange <berrange@redhat.com>2016-01-11 12:59:44 +0000
committerDaniel P. Berrange <berrange@redhat.com>2016-01-19 14:03:27 +0000
commitcc75a50c68ccea2068e76fc59e5492899abd3bdb (patch)
tree8f22092a51d37c3d01c3dd6d9d016683720987d3 /io
parent3db34bf64ab4f8797565dd8750003156c32b301d (diff)
io: fix sign of errno value passed to error report
When reporting the number of FDs has been exceeded, pass EINVAL to error_setg_errno, rather than -EINVAL. Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Diffstat (limited to 'io')
-rw-r--r--io/channel-socket.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/io/channel-socket.c b/io/channel-socket.c
index 10a5b3136e..eaa411f3d2 100644
--- a/io/channel-socket.c
+++ b/io/channel-socket.c
@@ -502,7 +502,7 @@ static ssize_t qio_channel_socket_writev(QIOChannel *ioc,
if (nfds) {
if (nfds > SOCKET_MAX_FDS) {
- error_setg_errno(errp, -EINVAL,
+ error_setg_errno(errp, EINVAL,
"Only %d FDs can be sent, got %zu",
SOCKET_MAX_FDS, nfds);
return -1;