| 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 "bin/process.h" | 5 #include "bin/process.h" |
| 6 | 6 |
| 7 #include <errno.h> | 7 #include <errno.h> |
| 8 #include <fcntl.h> | 8 #include <fcntl.h> |
| 9 #include <poll.h> | 9 #include <poll.h> |
| 10 #include <signal.h> | 10 #include <signal.h> |
| (...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 555 if (result == -1) { | 555 if (result == -1) { |
| 556 return false; | 556 return false; |
| 557 } | 557 } |
| 558 return true; | 558 return true; |
| 559 } | 559 } |
| 560 | 560 |
| 561 | 561 |
| 562 void Process::TerminateExitCodeHandler() { | 562 void Process::TerminateExitCodeHandler() { |
| 563 ExitCodeHandler::TerminateExitCodeThread(); | 563 ExitCodeHandler::TerminateExitCodeThread(); |
| 564 } | 564 } |
| 565 |
| 566 |
| 567 intptr_t Process::CurrentProcessId() { |
| 568 return static_cast<intptr_t>(getpid()); |
| 569 } |
| OLD | NEW |