summaryrefslogtreecommitdiffstats
path: root/regress.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-12 05:01:23 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-12 05:01:23 +0000
commitad8b7d9e228c894c12cc061770b1a39d037e90ab (patch)
treed5bee8d23cb0a8de0d2fcab6b74d5becc8598296 /regress.c
parentAdding upstream version 4.5. (diff)
downloadchrony-ad8b7d9e228c894c12cc061770b1a39d037e90ab.tar.xz
chrony-ad8b7d9e228c894c12cc061770b1a39d037e90ab.zip
Adding upstream version 4.6.upstream/4.6upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--regress.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/regress.c b/regress.c
index e767e2f..1c86457 100644
--- a/regress.c
+++ b/regress.c
@@ -377,7 +377,7 @@ find_ordered_entry_with_flags(double *x, int n, int index, char *flags)
r = v;
do {
while (l < v && x[l] < piv) l++;
- while (x[r] > piv) r--;
+ while (r > 0 && x[r] > piv) r--;
if (r <= l) break;
EXCH(x[l], x[r]);
l++;