Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
* [FFmpeg-devel] [PATCH 2/2] avformat/whip: Constify arguments in is_rtp_rtcp/is_rtcp
@ 2025-06-05  9:41 Zhao Zhili
  2025-06-05 13:03 ` Jack Lau
  0 siblings, 1 reply; 2+ messages in thread
From: Zhao Zhili @ 2025-06-05  9:41 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Zhao Zhili

From: Zhao Zhili <zhilizhao@tencent.com>

Fix warning of -Wincompatible-pointer-types-discards-qualifiers.
---
 libavformat/whip.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/whip.c b/libavformat/whip.c
index 0671e23635..710f24fc5a 100644
--- a/libavformat/whip.c
+++ b/libavformat/whip.c
@@ -1115,13 +1115,13 @@ static int ice_is_binding_response(uint8_t *b, int size)
  * The RTCP packet header is similar to RTP,
  * see https://www.rfc-editor.org/rfc/rfc3550#section-6.4.1
  */
-static int media_is_rtp_rtcp(uint8_t *b, int size)
+static int media_is_rtp_rtcp(const uint8_t *b, int size)
 {
     return size >= WHIP_RTP_HEADER_SIZE && (b[0] & 0xC0) == 0x80;
 }
 
 /* Whether the packet is RTCP. */
-static int media_is_rtcp(uint8_t *b, int size)
+static int media_is_rtcp(const uint8_t *b, int size)
 {
     return size >= WHIP_RTP_HEADER_SIZE && b[1] >= WHIP_RTCP_PT_START && b[1] <= WHIP_RTCP_PT_END;
 }
-- 
2.25.1

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [FFmpeg-devel] [PATCH 2/2] avformat/whip: Constify arguments in is_rtp_rtcp/is_rtcp
  2025-06-05  9:41 [FFmpeg-devel] [PATCH 2/2] avformat/whip: Constify arguments in is_rtp_rtcp/is_rtcp Zhao Zhili
@ 2025-06-05 13:03 ` Jack Lau
  0 siblings, 0 replies; 2+ messages in thread
From: Jack Lau @ 2025-06-05 13:03 UTC (permalink / raw)
  To: FFmpeg development discussions and patches



> On Jun 5, 2025, at 17:41, Zhao Zhili <quinkblack-at-foxmail.com@ffmpeg.org> wrote:
> 
> From: Zhao Zhili <zhilizhao@tencent.com>
> 
> Fix warning of -Wincompatible-pointer-types-discards-qualifiers.
> ---
> libavformat/whip.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/libavformat/whip.c b/libavformat/whip.c
> index 0671e23635..710f24fc5a 100644
> --- a/libavformat/whip.c
> +++ b/libavformat/whip.c
> @@ -1115,13 +1115,13 @@ static int ice_is_binding_response(uint8_t *b, int size)
>  * The RTCP packet header is similar to RTP,
>  * see https://www.rfc-editor.org/rfc/rfc3550#section-6.4.1
>  */
> -static int media_is_rtp_rtcp(uint8_t *b, int size)
> +static int media_is_rtp_rtcp(const uint8_t *b, int size)
> {
>     return size >= WHIP_RTP_HEADER_SIZE && (b[0] & 0xC0) == 0x80;
> }
> 
> /* Whether the packet is RTCP. */
> -static int media_is_rtcp(uint8_t *b, int size)
> +static int media_is_rtcp(const uint8_t *b, int size)
> {
>     return size >= WHIP_RTP_HEADER_SIZE && b[1] >= WHIP_RTCP_PT_START && b[1] <= WHIP_RTCP_PT_END;
> }
> -- 
> 2.25.1
LGTM

Thanks
Jack
> 
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-06-05 13:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-06-05  9:41 [FFmpeg-devel] [PATCH 2/2] avformat/whip: Constify arguments in is_rtp_rtcp/is_rtcp Zhao Zhili
2025-06-05 13:03 ` Jack Lau

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git