Skip to content

Commit

Permalink
Include <time.h> when calling time(2).
Browse files Browse the repository at this point in the history
Rather than rely on "gtest/gtest.h" to include <time.h>, include it
explicitly, to ensure that time(2) is declared.
  • Loading branch information
sunfishcode authored and EdSchouten committed Apr 26, 2019
1 parent 8835639 commit 33041bf
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/libc/unistd/sleep_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
// SPDX-License-Identifier: BSD-2-Clause

#include <unistd.h>
#include <time.h>

#include "gtest/gtest.h"

Expand Down

0 comments on commit 33041bf

Please sign in to comment.