[Lldb-commits] [lldb] [lldb] PopulatePrpsInfoTest can fail due to hardcoded priority value (PR #104617)
David Spickett via lldb-commits
lldb-commits at lists.llvm.org
Mon Aug 19 02:21:35 PDT 2024
================
@@ -120,7 +121,10 @@ TEST_F(ElfCoreTest, PopulatePrpsInfoTest) {
ASSERT_EQ(prpsinfo_opt->pr_state, 0);
ASSERT_EQ(prpsinfo_opt->pr_sname, 'R');
ASSERT_EQ(prpsinfo_opt->pr_zomb, 0);
- ASSERT_EQ(prpsinfo_opt->pr_nice, 0);
+ int priority = getpriority(PRIO_PROCESS, getpid());
+ if (priority == -1)
----------------
DavidSpickett wrote:
Are you assuming that the priority of the debugged process is the same as the test process, or is the debugged process in fact the same as the test process?
https://github.com/llvm/llvm-project/pull/104617
More information about the lldb-commits
mailing list