From 983a703ba75abb65a95ed45eb25668d0e44c6aa6 Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Thu, 6 May 2021 12:33:40 -0400 Subject: [PATCH] TT#111150 remove stray compiler warning Some invocations of ssrc_ctx_put() are deliberately passed a memory reference, which produces an undesired compiler warning. Use an intermediate variable to suppress it. Change-Id: I7a5000df4d66ffadd374475907460919763c95b0 --- include/ssrc.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/include/ssrc.h b/include/ssrc.h index bd8737b30..1b219b665 100644 --- a/include/ssrc.h +++ b/include/ssrc.h @@ -215,14 +215,15 @@ void payload_tracker_add(struct payload_tracker *, int); #define ssrc_ctx_put(c) \ do { \ - if ((c) && *(c)) { \ - obj_put(&(*c)->parent->h); \ - *(c) = NULL; \ + struct ssrc_ctx **__cc = (c); \ + if ((__cc) && *(__cc)) { \ + obj_put(&(*__cc)->parent->h); \ + *(__cc) = NULL; \ } \ } while (0) #define ssrc_ctx_hold(c) \ do { \ - if ((c)) \ + if (c) \ obj_hold(&(c)->parent->h); \ } while (0)