Commit d7768a1c authored by Fabrice de Gans-Riberi's avatar Fabrice de Gans-Riberi Committed by Commit Bot

[fuchsia] Update zx_clock_get_new -> zx_clock_get

The call was renamed in Fuchsia, the transitional *_new variant is
going to be removed soon.

Bug: 977753
Change-Id: I4d189066cb7ceff1ed4bfc18a9a434a3c2e6ec34
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1677010
Commit-Queue: Fabrice de Gans-Riberi <fdegans@chromium.org>
Commit-Queue: Wez <wez@chromium.org>
Auto-Submit: Fabrice de Gans-Riberi <fdegans@chromium.org>
Reviewed-by: default avatarWez <wez@chromium.org>
Cr-Commit-Position: refs/heads/master@{#672188}
parent 51717d15
......@@ -16,7 +16,7 @@ namespace base {
namespace subtle {
Time TimeNowIgnoringOverride() {
zx_time_t nanos_since_unix_epoch;
zx_status_t status = zx_clock_get_new(ZX_CLOCK_UTC, &nanos_since_unix_epoch);
zx_status_t status = zx_clock_get(ZX_CLOCK_UTC, &nanos_since_unix_epoch);
ZX_CHECK(status == ZX_OK, status);
// The following expression will overflow in the year 289938 A.D.:
return Time::FromZxTime(nanos_since_unix_epoch);
......@@ -86,7 +86,7 @@ namespace subtle {
ThreadTicks ThreadTicksNowIgnoringOverride() {
zx_time_t nanos_since_thread_started;
zx_status_t status =
zx_clock_get_new(ZX_CLOCK_THREAD, &nanos_since_thread_started);
zx_clock_get(ZX_CLOCK_THREAD, &nanos_since_thread_started);
ZX_CHECK(status == ZX_OK, status);
DCHECK(nanos_since_thread_started != 0);
return ThreadTicks() + TimeDelta::FromNanoseconds(nanos_since_thread_started);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment