Skip to content

Commit 5626de6

Browse files
rchatrehansendc
authored andcommitted
selftests/sgx: Remove extra newlines in test output
The TH_LOG() macro is an optional debug logging function made available by kselftest itself. When TH_LOG_ENABLED is set it prints the provided message with additional information and formatting that already includes a newline. Providing a newline to the message printed by TH_LOG() results in a double newline that produces irregular test output. Remove the unnecessary newlines from the text provided to TH_LOG(). Fixes: 1b35eb7 ("selftests/sgx: Encpsulate the test enclave creation") Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Acked-by: Dave Hansen <dave.hansen@linux.intel.com> Acked-by: Shuah Khan <skhan@linuxfoundation.org> Link: https://lkml.kernel.org/r/6fd171ba622aed172a7c5b129d34d50bd0482f24.1644355600.git.reinette.chatre@intel.com
1 parent 2db703f commit 5626de6

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • tools/testing/selftests/sgx

tools/testing/selftests/sgx/main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ static bool setup_test_encl(unsigned long heap_size, struct encl *encl,
146146

147147
if (!encl_load("test_encl.elf", encl, heap_size)) {
148148
encl_delete(encl);
149-
TH_LOG("Failed to load the test enclave.\n");
149+
TH_LOG("Failed to load the test enclave.");
150150
return false;
151151
}
152152

@@ -204,7 +204,7 @@ static bool setup_test_encl(unsigned long heap_size, struct encl *encl,
204204
fclose(maps_file);
205205
}
206206

207-
TH_LOG("Failed to initialize the test enclave.\n");
207+
TH_LOG("Failed to initialize the test enclave.");
208208

209209
encl_delete(encl);
210210

0 commit comments

Comments
 (0)