Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(236)

Unified Diff: compat/win/time.cc

Issue 1119783005: win: get tools/crashpad_database_util mostly working (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@master
Patch Set: sort Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: compat/win/time.cc
diff --git a/test/thread.cc b/compat/win/time.cc
similarity index 56%
copy from test/thread.cc
copy to compat/win/time.cc
index baeeafa632152c4edd71aa04be6a4d32a0824d2e..eb511d85c85ca9b0736a98bc4816196e769b7bdb 100644
--- a/test/thread.cc
+++ b/compat/win/time.cc
@@ -12,19 +12,25 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-#include "test/thread.h"
+#include <time.h>
-#include "gtest/gtest.h"
-
-namespace crashpad {
-namespace test {
+struct tm* gmtime_r(const time_t* timep, struct tm* result) {
+ if (gmtime_s(result, timep) != 0)
+ return nullptr;
+ return result;
+}
-Thread::Thread() : platform_thread_(0) {
+struct tm* localtime_r(const time_t* timep, struct tm* result) {
+ if (localtime_s(result, timep) != 0)
+ return nullptr;
+ return result;
}
-Thread::~Thread() {
- EXPECT_FALSE(platform_thread_);
+const char* strptime(const char* buf, const char* format, struct tm* tm) {
+ // TODO(scottmg): strptime implementation.
+ return nullptr;
}
-} // namespace test
-} // namespace crashpad
+time_t timegm(struct tm* tm) {
+ return _mkgmtime(tm);
+}

Powered by Google App Engine
This is Rietveld 408576698