summaryrefslogtreecommitdiffhomepage
path: root/test/syscalls/linux/sigaltstack.cc
diff options
context:
space:
mode:
authorMichael Pratt <mpratt@google.com>2019-12-03 12:45:43 -0800
committergVisor bot <gvisor-bot@google.com>2019-12-03 12:47:03 -0800
commitd7cc2480cb6e465ce01eb245e7edbad2c68c44d8 (patch)
tree584a6bf59ce62e76382010252fea5ba5fb1e143f /test/syscalls/linux/sigaltstack.cc
parent812189664cab0a17ae29095e4029e2f8762a6779 (diff)
Add RunfilesPath to test_util
A few tests have their own ad-hoc implementations. Add a single common one. PiperOrigin-RevId: 283601666
Diffstat (limited to 'test/syscalls/linux/sigaltstack.cc')
-rw-r--r--test/syscalls/linux/sigaltstack.cc8
1 files changed, 1 insertions, 7 deletions
diff --git a/test/syscalls/linux/sigaltstack.cc b/test/syscalls/linux/sigaltstack.cc
index 6fd3989a4..a778fa639 100644
--- a/test/syscalls/linux/sigaltstack.cc
+++ b/test/syscalls/linux/sigaltstack.cc
@@ -95,13 +95,7 @@ TEST(SigaltstackTest, ResetByExecve) {
auto const cleanup_sigstack =
ASSERT_NO_ERRNO_AND_VALUE(ScopedSigaltstack(stack));
- std::string full_path;
- char* test_src = getenv("TEST_SRCDIR");
- if (test_src) {
- full_path = JoinPath(test_src, "../../linux/sigaltstack_check");
- }
-
- ASSERT_FALSE(full_path.empty());
+ std::string full_path = RunfilePath("test/syscalls/linux/sigaltstack_check");
pid_t child_pid = -1;
int execve_errno = 0;