From c98c6d74795ed1e757da1ee2afb48d3fb09d7f91 Mon Sep 17 00:00:00 2001 From: Ulisses Furquim Date: Tue, 5 Sep 2006 20:48:59 +0000 Subject: Fix functions to return negative error values --- hcid/dbus-sdp.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/hcid/dbus-sdp.c b/hcid/dbus-sdp.c index fbf8ac2b..7ad41a6c 100644 --- a/hcid/dbus-sdp.c +++ b/hcid/dbus-sdp.c @@ -837,7 +837,7 @@ static int remote_svc_rec_conn_cb(struct transaction_context *ctxt) if (sdp_set_notify(ctxt->session, remote_svc_rec_completed_cb, ctxt) < 0) { error("Invalid session data!"); - err = EINVAL; + err = -EINVAL; goto fail; } @@ -850,7 +850,7 @@ static int remote_svc_rec_conn_cb(struct transaction_context *ctxt) /* Create/send the search request and set the callback to indicate the request completion */ if (sdp_service_attr_async(ctxt->session, handle, SDP_ATTR_REQ_RANGE, attrids) < 0) { error("send request failed: %s (%d)", strerror(errno), errno); - err = errno; + err = -errno; goto fail; } @@ -894,7 +894,7 @@ static int remote_svc_handles_conn_cb(struct transaction_context *ctxt) if (sdp_set_notify(ctxt->session, remote_svc_handles_completed_cb, ctxt) < 0) { error("Invalid session data!"); - err = EINVAL; + err = -EINVAL; goto fail; } @@ -905,7 +905,7 @@ static int remote_svc_handles_conn_cb(struct transaction_context *ctxt) /* Create/send the search request and set the callback to indicate the request completion */ if (sdp_service_search_attr_async(ctxt->session, search, SDP_ATTR_REQ_RANGE, attrids) < 0) { error("send request failed: %s (%d)", strerror(errno), errno); - err = errno; + err = -errno; goto fail; } -- cgit