ffmpeg | branch: release/6.0 | Marton Balint <c...@passwd.hu> | Mon Feb 5 00:31:27 2024 +0100| [9dbeb1d5d0f4fbc9bdc943c869a6e312f12074a8] | committer: Brad Smith
avutil/thread: fix pthread_setname_np parameters for NetBSD and Apple Signed-off-by: Marton Balint <c...@passwd.hu> (cherry picked from commit 71ea90638efa56b4cd006bfa6cfb464d2169692d) Signed-off-by: Brad Smith <b...@comstyle.com> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9dbeb1d5d0f4fbc9bdc943c869a6e312f12074a8 --- libavutil/thread.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/libavutil/thread.h b/libavutil/thread.h index 5203edf494..8023ad303d 100644 --- a/libavutil/thread.h +++ b/libavutil/thread.h @@ -201,7 +201,13 @@ static inline int ff_thread_setname(const char *name) #if HAVE_PRCTL ret = AVERROR(prctl(PR_SET_NAME, name)); #elif HAVE_PTHREAD_SETNAME_NP +#if defined(__APPLE__) + ret = AVERROR(pthread_setname_np(name)); +#elif defined(__NetBSD__) + ret = AVERROR(pthread_setname_np(pthread_self(), "%s", name)); +#else ret = AVERROR(pthread_setname_np(pthread_self(), name)); +#endif #elif HAVE_PTHREAD_SET_NAME_NP pthread_set_name_np(pthread_self(), name); #else _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".