From a9b567a98da11f2c64a6e1d01b9329ed89217b95 Mon Sep 17 00:00:00 2001 From: Szymon Janc Date: Tue, 28 Aug 2012 15:33:16 +0200 Subject: [PATCH] sdp: Fix error reporting in sdp_service_search_attr_req This function reports error code via errno not return value. --- lib/sdp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/sdp.c b/lib/sdp.c index 9807c8d97..36b4d08da 100644 --- a/lib/sdp.c +++ b/lib/sdp.c @@ -4346,7 +4346,8 @@ int sdp_service_search_attr_req(sdp_session_t *session, const sdp_list_t *search seqlen = gen_attridseq_pdu(pdata, attrids, reqtype == SDP_ATTR_REQ_INDIVIDUAL ? SDP_UINT16 : SDP_UINT32); if (seqlen == -1) { - status = EINVAL; + errno = EINVAL; + status = -1; goto end; } pdata += seqlen; -- 2.47.3