summaryrefslogtreecommitdiffstats
path: root/sandbox/linux/seccomp/gettid.cc
blob: 14233835e13a7c4f032c169c282507daa2b2e8d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "debug.h"
#include "sandbox_impl.h"

namespace playground {

int Sandbox::sandbox_gettid() {
  long long tm;
  Debug::syscall(&tm, __NR_gettid, "Executing handler");
  pid_t t = tid();
  Debug::elapsed(tm, __NR_gettid);
  return t;
}

} // namespace