mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-31 01:11:12 +02:00
set_threadname: silence "overlapping src/dest" valgrind warning
This might be a false positive, but the fix does not harm ;)
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
inline void set_threadname(const char *name)
|
||||
{
|
||||
char threadname[17];
|
||||
strncpy(threadname, name, sizeof(threadname));
|
||||
strncpy(threadname, name, 16);
|
||||
threadname[16] = 0;
|
||||
prctl (PR_SET_NAME, (unsigned long)threadname);
|
||||
}
|
||||
|
Reference in New Issue
Block a user