diff options
author | Justin Cohen <justincohen@google.com> | 2022-06-06 22:51:50 -0400 |
---|---|---|
committer | WebRTC LUCI CQ <webrtc-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-06-07 07:14:06 +0000 |
commit | 45d66a59d6dc65a228fee7df6dc8290de694481f (patch) | |
tree | c53b4ded7bd57367a18bb1f4f88d5da57d9daeaf /rtc_base/http_common.cc | |
parent | eef9d5d6e10765e8c9374b6ef6bc0fb9fe6e1f1a (diff) | |
download | webrtc-45d66a59d6dc65a228fee7df6dc8290de694481f.tar.gz |
Fix usage of sprintf.
sprintf is marked as deprecated with Xcode 14.
Bug: chromium:1331345
Change-Id: Ib7eb7ab829457f3ef5fcad44b43fe827359ad7d4
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/265200
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Auto-Submit: Justin Cohen <justincohen@google.com>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#37136}
Diffstat (limited to 'rtc_base/http_common.cc')
-rw-r--r-- | rtc_base/http_common.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rtc_base/http_common.cc b/rtc_base/http_common.cc index 2968cf12c3..621b854b53 100644 --- a/rtc_base/http_common.cc +++ b/rtc_base/http_common.cc @@ -305,7 +305,7 @@ HttpAuthResult HttpAuthenticate(absl::string_view challenge, std::string cnonce, ncount; char buffer[256]; - sprintf(buffer, "%d", static_cast<int>(time(0))); + snprintf(buffer, sizeof(buffer), "%d", static_cast<int>(time(0))); cnonce = MD5(buffer); ncount = "00000001"; |