Skip to content

Commit

Permalink
Rename something
Browse files Browse the repository at this point in the history
  • Loading branch information
mrousavy committed Jan 22, 2025
1 parent c9567e9 commit 6f2c779
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ namespace margelo::nitro {
std::string ThreadUtils::getThreadName() {
#ifdef HAVE_ANDROID_PTHREAD_SETNAME_NP
// Try using pthread APIs
pthread_t this_thread = pthread_self();
char thread_name[16]; // Thread name length limit in Android is 16 characters
pthread_t thisThread = pthread_self();
char threadName[16]; // Thread name length limit in Android is 16 characters

int result = pthread_getname_np(this_thread, thread_name, sizeof(thread_name));
int result = pthread_getname_np(thisThread, threadName, sizeof(threadName));
if (result == 0) {
return std::string(thread_name);
return std::string(threadName);
}
#endif

Expand Down

0 comments on commit 6f2c779

Please sign in to comment.