From: Stefan Knoblich Date: Mon, 30 Jul 2012 11:56:48 +0000 (+0200) Subject: FreeSWITCH: Fix warn-unused-result error in rtp_common_read(). X-Git-Tag: v1.2.0~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3c82033e532081fb42678a2ba297f9bd32b94635;p=thirdparty%2Ffreeswitch.git FreeSWITCH: Fix warn-unused-result error in rtp_common_read(). strerror_r() returns the error message string (and expects you to use it). Signed-off-by: Stefan Knoblich --- diff --git a/src/switch_rtp.c b/src/switch_rtp.c index f0749d8087..867f600f47 100644 --- a/src/switch_rtp.c +++ b/src/switch_rtp.c @@ -3310,8 +3310,8 @@ static int rtp_common_read(switch_rtp_t *rtp_session, switch_payload_t *payload_ if (!SWITCH_STATUS_IS_BREAK(poll_status) && poll_status != SWITCH_STATUS_TIMEOUT) { char tmp[128] = ""; - strerror_r(poll_status, tmp, sizeof(tmp)); - switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Poll failed with error: %d [%s]\n", poll_status, tmp); + switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Poll failed with error: %d [%s]\n", + poll_status, strerror_r(poll_status, tmp, sizeof(tmp))); ret = -1; goto end; }