summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortb <>2024-03-04 09:47:34 +0000
committertb <>2024-03-04 09:47:34 +0000
commitd0e8f177920957bd9687a40413024059472ef42b (patch)
tree634a123ae637137abb3fb313cdebf4ff2626133d /src
parent77adb65fa66009ad5786acbeac45de1e0e79a520 (diff)
downloadopenbsd-d0e8f177920957bd9687a40413024059472ef42b.tar.gz
openbsd-d0e8f177920957bd9687a40413024059472ef42b.tar.bz2
openbsd-d0e8f177920957bd9687a40413024059472ef42b.zip
Remove docs for sk_find_ex()
Diffstat (limited to 'src')
-rw-r--r--src/lib/libcrypto/man/OPENSSL_sk_new.350
1 files changed, 3 insertions, 47 deletions
diff --git a/src/lib/libcrypto/man/OPENSSL_sk_new.3 b/src/lib/libcrypto/man/OPENSSL_sk_new.3
index 5df45534f7..8f06bb4212 100644
--- a/src/lib/libcrypto/man/OPENSSL_sk_new.3
+++ b/src/lib/libcrypto/man/OPENSSL_sk_new.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: OPENSSL_sk_new.3,v 1.12 2021/03/12 05:18:00 jsg Exp $ 1.\" $OpenBSD: OPENSSL_sk_new.3,v 1.13 2024/03/04 09:47:34 tb Exp $
2.\" 2.\"
3.\" Copyright (c) 2018 Ingo Schwarze <schwarze@openbsd.org> 3.\" Copyright (c) 2018 Ingo Schwarze <schwarze@openbsd.org>
4.\" 4.\"
@@ -14,7 +14,7 @@
14.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 14.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 15.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16.\" 16.\"
17.Dd $Mdocdate: March 12 2021 $ 17.Dd $Mdocdate: March 4 2024 $
18.Dt OPENSSL_SK_NEW 3 18.Dt OPENSSL_SK_NEW 3
19.Os 19.Os
20.Sh NAME 20.Sh NAME
@@ -27,7 +27,6 @@
27.Nm sk_num , 27.Nm sk_num ,
28.Nm sk_value , 28.Nm sk_value ,
29.Nm sk_find , 29.Nm sk_find ,
30.Nm sk_find_ex ,
31.Nm sk_sort , 30.Nm sk_sort ,
32.Nm sk_is_sorted , 31.Nm sk_is_sorted ,
33.Nm sk_push , 32.Nm sk_push ,
@@ -80,11 +79,6 @@
80.Fa "_STACK *stack" 79.Fa "_STACK *stack"
81.Fa "void *wanted" 80.Fa "void *wanted"
82.Fc 81.Fc
83.Ft int
84.Fo sk_find_ex
85.Fa "_STACK *stack"
86.Fa "void *wanted"
87.Fc
88.Ft void 82.Ft void
89.Fo sk_sort 83.Fo sk_sort
90.Fa "_STACK *stack" 84.Fa "_STACK *stack"
@@ -245,16 +239,6 @@ first sorted with
245and instead of comparing pointers, two pointers are considered to match 239and instead of comparing pointers, two pointers are considered to match
246if the comparison function returns 0. 240if the comparison function returns 0.
247.Pp 241.Pp
248.Fn sk_find_ex
249is identical to
250.Fn sk_find
251except that if the
252.Fa stack
253is not empty but no match is found,
254the index of some pointer considered closest to
255.Fa wanted
256is returned.
257.Pp
258.Fn sk_sort 242.Fn sk_sort
259sorts the 243sorts the
260.Fa stack 244.Fa stack
@@ -285,9 +269,8 @@ or
285or changing the comparison function sets the state to unsorted. 269or changing the comparison function sets the state to unsorted.
286If a comparison function is installed, calling 270If a comparison function is installed, calling
287.Fn sk_sort , 271.Fn sk_sort ,
288.Fn sk_find ,
289or 272or
290.Fn sk_find_ex 273.Fn sk_find
291sets the state to sorted. 274sets the state to sorted.
292.Pp 275.Pp
293.Fn sk_push 276.Fn sk_push
@@ -456,13 +439,6 @@ is a
456.Dv NULL 439.Dv NULL
457pointer or if no match is found. 440pointer or if no match is found.
458.Pp 441.Pp
459.Fn sk_find_ex
460returns some index or \-1 if
461.Fa stack
462is a
463.Dv NULL
464pointer or empty.
465.Pp
466.Fn sk_is_sorted 442.Fn sk_is_sorted
467returns 1 if the 443returns 1 if the
468.Fa stack 444.Fa stack
@@ -562,10 +538,6 @@ Both functions have been available since
562.Fn sk_is_sorted 538.Fn sk_is_sorted
563first appeared in OpenSSL 0.9.7e and has been available since 539first appeared in OpenSSL 0.9.7e and has been available since
564.Ox 3.8 . 540.Ox 3.8 .
565.Pp
566.Fn sk_find_ex
567first appeared in OpenSSL 0.9.8 and has been available since
568.Ox 4.5 .
569.Sh BUGS 541.Sh BUGS
570Even if a comparison function is installed, empty stacks and 542Even if a comparison function is installed, empty stacks and
571stacks containing a single pointer are sometimes considered 543stacks containing a single pointer are sometimes considered
@@ -575,23 +547,7 @@ If a comparison function is installed, the concept of
575.Dq first match 547.Dq first match
576in 548in
577.Fn sk_find 549.Fn sk_find
578and
579.Fn sk_find_ex
580is ill-defined because 550is ill-defined because
581.Xr qsort 3 551.Xr qsort 3
582is not a stable sorting function. 552is not a stable sorting function.
583It is probably best to only assume that they return an arbitrary match. 553It is probably best to only assume that they return an arbitrary match.
584.Pp
585The concept of
586.Dq closest
587for
588.Fn sk_find_ex
589is even less clearly defined.
590The match may sometimes be smaller and sometimes larger than
591.Fa wanted ,
592even if both smaller and larger pointers exist in the
593.Fa stack .
594Besides, it is again ill-defined
595which of several pointers that compare equal is selected.
596It is probably best to not assume anything about the selection
597for cases where there is no match.