mirror of
https://github.com/wolfpld/tracy
synced 2025-04-29 12:23:53 +00:00
Fix implementation errors.
This commit is contained in:
parent
bd622c304a
commit
6c1d014aa3
@ -2,6 +2,7 @@
|
|||||||
# include <windows.h>
|
# include <windows.h>
|
||||||
#else
|
#else
|
||||||
# include <pthread.h>
|
# include <pthread.h>
|
||||||
|
# include <string.h>
|
||||||
# include <unistd.h>
|
# include <unistd.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -58,9 +59,9 @@ void SetThreadName( std::thread& thread, const char* name )
|
|||||||
char buf[16];
|
char buf[16];
|
||||||
memcpy( buf, name, 15 );
|
memcpy( buf, name, 15 );
|
||||||
buf[15] = '\0';
|
buf[15] = '\0';
|
||||||
pthread_setname_np( thread.native_handle(), sz );
|
pthread_setname_np( thread.native_handle(), buf );
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user