NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: lib/60949 (pthread_getname_np can write to empty buffer if there is no thread name)



Synopsis: pthread_getname_np can write to empty buffer if there is no thread name

Responsible-Changed-From-To: lib-bug-people->kre
Responsible-Changed-By: kre%NetBSD.org@localhost
Responsible-Changed-When: Sun, 01 Nov 2026 18:00:25 +0000
Responsible-Changed-Why:
I will fix this one.   It turns out that pthread_attr_getname_np(3) has the same issue,
so I will fix that as well.

In each case a len of 0 will become an error (which according to the man page would
be the only error possible from pthread_attr_getname_np(3) - but that was always
wrong, an invalid "attr" arg already returned EINVAL - so that man page needs an
update as well).

Since one could argue that any application which gives 0 as the length of the buffer
for either of those functions deserves whatever befalls it, and no sane application
ever would, I doubt this really needs pulling up to the released versions.






Home | Main Index | Thread Index | Old Index