#include <android-base/file.h>
#include <android-base/stringprintf.h>
#include <android-base/test_utils.h>
-#include <sys/syscall.h>
#include <thread>
#include "command.h"
+#include "environment.h"
#include "get_test_data.h"
#include "test_util.h"
TEST(stat_cmd, stop_when_no_more_targets) {
std::atomic<int> tid(0);
std::thread thread([&]() {
- tid = syscall(__NR_gettid);
+ tid = gettid();
sleep(1);
});
thread.detach();