From c542e49ae918754b15e9089fb79d7f95bb83c7c3 Mon Sep 17 00:00:00 2001 From: Michael Scire Date: Tue, 2 Nov 2021 10:09:15 -0700 Subject: [PATCH] dmnt2: try to avoid writing out of bounds when generating packets --- libstratosphere/source/osdbg/osdbg_thread.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libstratosphere/source/osdbg/osdbg_thread.cpp b/libstratosphere/source/osdbg/osdbg_thread.cpp index 81f69ad5..6bb9235e 100644 --- a/libstratosphere/source/osdbg/osdbg_thread.cpp +++ b/libstratosphere/source/osdbg/osdbg_thread.cpp @@ -50,9 +50,9 @@ namespace ams::osdbg { } else { /* Special-case libnx threads. */ if (thread_info->_thread_type_type == ThreadTypeType_Libnx) { - util::TSNPrintf(dst, os::ThreadNameLengthMax, "libnx Thread_%p", reinterpret_cast(thread_info->_thread_type)); + util::TSNPrintf(dst, os::ThreadNameLengthMax, "libnx Thread_0x%010lx", reinterpret_cast(thread_info->_thread_type)); } else { - util::TSNPrintf(dst, os::ThreadNameLengthMax, "Thread_%p", reinterpret_cast(thread_info->_thread_type)); + util::TSNPrintf(dst, os::ThreadNameLengthMax, "Thread_0x%010lx", reinterpret_cast(thread_info->_thread_type)); } return ResultSuccess();