Skip to content

Commit

Permalink
Merge pull request #2546 from signalwire/risky
Browse files Browse the repository at this point in the history
[Core] switch_rtp_create: Coverity 1227620 Calling risky function
  • Loading branch information
andywolk authored Jul 29, 2024
2 parents 4eefe82 + b43ae84 commit 43f8ffb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/switch_rtp.c
Original file line number Diff line number Diff line change
Expand Up @@ -4517,7 +4517,7 @@ SWITCH_DECLARE(switch_status_t) switch_rtp_create(switch_rtp_t **new_rtp_session
switch_sockaddr_create(&rtp_session->rtcp_from_addr, pool);
}

rtp_session->seq = (uint16_t) rand();
rtp_session->seq = (uint16_t) switch_rand();
rtp_session->ssrc = (uint32_t) ((intptr_t) rtp_session + (switch_time_t) switch_epoch_time_now(NULL));
#ifdef DEBUG_TS_ROLLOVER
rtp_session->last_write_ts = TS_ROLLOVER_START;
Expand Down

0 comments on commit 43f8ffb

Please sign in to comment.