NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
PR/58154 CVS commit: src/libexec/ld.elf_so
The following reply was made to PR lib/58154; it has been noted by GNATS.
From: "Taylor R Campbell" <riastradh%netbsd.org@localhost>
To: gnats-bugs%gnats.NetBSD.org@localhost
Cc:
Subject: PR/58154 CVS commit: src/libexec/ld.elf_so
Date: Tue, 23 Jul 2024 22:00:00 +0000
Module Name: src
Committed By: riastradh
Date: Tue Jul 23 22:00:00 UTC 2024
Modified Files:
src/libexec/ld.elf_so: tls.c
Log Message:
ld.elf_so: Fix off-by-one error in common __tls_get_addr.
DTV_MAX_INDEX(dtv) is an _inclusive_ upper bound, i.e., the actual
maximum value of the allowed indices. It is not an exclusive upper
bound -- it is not the number of allowed indices.
This off-by-one doesn't hurt correctness, but it may hurt performance
by using the slow path when the fast path would be safe.
Found by pho@ in PR lib/58154.
To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/libexec/ld.elf_so/tls.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Home |
Main Index |
Thread Index |
Old Index