| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include <errno.h> | 5 #include <errno.h> |
| 6 #include <limits.h> | 6 #include <limits.h> |
| 7 #include <time.h> | 7 #include <time.h> |
| 8 #include <sys/resource.h> | 8 #include <sys/resource.h> |
| 9 #include <sys/time.h> | 9 #include <sys/time.h> |
| 10 #include <sys/types.h> | 10 #include <sys/types.h> |
| 11 #include <unistd.h> | 11 #include <unistd.h> |
| 12 | 12 |
| 13 #include "platform/utils.h" |
| 13 #include "vm/isolate.h" | 14 #include "vm/isolate.h" |
| 14 #include "vm/os.h" | 15 #include "vm/os.h" |
| 15 #include "vm/utils.h" | |
| 16 | 16 |
| 17 namespace dart { | 17 namespace dart { |
| 18 | 18 |
| 19 bool OS::BreakDownSecondsSinceEpoch(time_t seconds_since_epoch, | 19 bool OS::BreakDownSecondsSinceEpoch(time_t seconds_since_epoch, |
| 20 bool in_utc, | 20 bool in_utc, |
| 21 BrokenDownDate* result) { | 21 BrokenDownDate* result) { |
| 22 struct tm tm_result; | 22 struct tm tm_result; |
| 23 struct tm* error_code; | 23 struct tm* error_code; |
| 24 if (in_utc) { | 24 if (in_utc) { |
| 25 error_code = gmtime_r(&seconds_since_epoch, &tm_result); | 25 error_code = gmtime_r(&seconds_since_epoch, &tm_result); |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 219 void OS::Abort() { | 219 void OS::Abort() { |
| 220 abort(); | 220 abort(); |
| 221 } | 221 } |
| 222 | 222 |
| 223 | 223 |
| 224 void OS::Exit(int code) { | 224 void OS::Exit(int code) { |
| 225 exit(code); | 225 exit(code); |
| 226 } | 226 } |
| 227 | 227 |
| 228 } // namespace dart | 228 } // namespace dart |
| OLD | NEW |