mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-01 09:51:13 +02:00
set_threadname: silence "overlapping src/dest" valgrind warning
This might be a false positive, but the fix does not harm ;)
Origin commit data
------------------
Branch: ni/coolstream
Commit: b36c2b03d6
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2016-01-03 (Sun, 03 Jan 2016)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -7,7 +7,7 @@
|
|||||||
inline void set_threadname(const char *name)
|
inline void set_threadname(const char *name)
|
||||||
{
|
{
|
||||||
char threadname[17];
|
char threadname[17];
|
||||||
strncpy(threadname, name, sizeof(threadname));
|
strncpy(threadname, name, 16);
|
||||||
threadname[16] = 0;
|
threadname[16] = 0;
|
||||||
prctl (PR_SET_NAME, (unsigned long)threadname);
|
prctl (PR_SET_NAME, (unsigned long)threadname);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user