]> git.saurik.com Git - wxWidgets.git/commitdiff
Use correct format specifier for thread id in the sample.
authorVadim Zeitlin <vadim@wxwidgets.org>
Wed, 17 Aug 2011 10:35:29 +0000 (10:35 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Wed, 17 Aug 2011 10:35:29 +0000 (10:35 +0000)
Thread id is an (unsigned) long, not just unsigned, so use "%lx" to print it
instead of "%x" to avoid asserts in formatting code.

Closes #13404.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68757 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

samples/thread/thread.cpp

index 6b0903cb827b522220947cb4b8fbca3c7cee5fd8..1e5c3ee9fb7317a41ee866d709d6ffc7c1c74c62 100644 (file)
@@ -479,7 +479,7 @@ MyFrame::DoLogRecord(wxLogLevel level,
         wxDateTime(info.timestamp).FormatISOTime(),
         info.threadId == wxThread::GetMainId()
             ? wxString("main")
-            : wxString::Format("%x", info.threadId),
+            : wxString::Format("%lx", info.threadId),
         msg + "\n"
     );
 }