OLD | NEW |
1 // Copyright (c) 2012, 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 "vm/globals.h" | 5 #include "vm/globals.h" |
6 #if defined(TARGET_OS_ANDROID) | 6 #if defined(TARGET_OS_ANDROID) |
7 | 7 |
8 #include "vm/os.h" | 8 #include "vm/os.h" |
9 | 9 |
10 #include <android/log.h> // NOLINT | 10 #include <android/log.h> // NOLINT |
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
274 } | 274 } |
275 // We should only ever see an interrupt error. | 275 // We should only ever see an interrupt error. |
276 ASSERT(errno == EINTR); | 276 ASSERT(errno == EINTR); |
277 // Copy remainder into requested and repeat. | 277 // Copy remainder into requested and repeat. |
278 req = rem; | 278 req = rem; |
279 } | 279 } |
280 } | 280 } |
281 | 281 |
282 | 282 |
283 void OS::DebugBreak() { | 283 void OS::DebugBreak() { |
284 UNIMPLEMENTED(); | 284 __builtin_trap(); |
285 } | 285 } |
286 | 286 |
287 | 287 |
288 char* OS::StrNDup(const char* s, intptr_t n) { | 288 char* OS::StrNDup(const char* s, intptr_t n) { |
289 return strndup(s, n); | 289 return strndup(s, n); |
290 } | 290 } |
291 | 291 |
292 | 292 |
293 uint16_t HostToBigEndian16(uint16_t value) { | 293 uint16_t HostToBigEndian16(uint16_t value) { |
294 return htobe16(value); | 294 return htobe16(value); |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
415 } | 415 } |
416 | 416 |
417 | 417 |
418 void OS::Exit(int code) { | 418 void OS::Exit(int code) { |
419 exit(code); | 419 exit(code); |
420 } | 420 } |
421 | 421 |
422 } // namespace dart | 422 } // namespace dart |
423 | 423 |
424 #endif // defined(TARGET_OS_ANDROID) | 424 #endif // defined(TARGET_OS_ANDROID) |
OLD | NEW |