summaryrefslogtreecommitdiff
path: root/crypto/stack/stack.c
diff options
context:
space:
mode:
authorsteve <steve>2000-06-16 23:29:03 +0000
committersteve <steve>2000-06-16 23:29:03 +0000
commit0c5c2981e22c86bf965034dce5b240486db1c53e (patch)
tree018921675a99fb39da9ebef0293a7b4a509ca332 /crypto/stack/stack.c
parent9e5c2c9e70768615a1eeba91437453e3f2e70e35 (diff)
downloadopenssl-0c5c2981e22c86bf965034dce5b240486db1c53e.tar.gz
Safe stack reorganisation in terms of function casts.
After some messing around this seems to work but needs a few more tests. Working out the syntax for sk_set_cmp_func() (cast it to a function that itself returns a function pointer) was painful :-( Needs some testing to see what other compilers think of this syntax. Also needs similar stuff for ASN1_SET_OF etc etc.
Diffstat (limited to 'crypto/stack/stack.c')
-rw-r--r--crypto/stack/stack.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/crypto/stack/stack.c b/crypto/stack/stack.c
index b3e32a759..2eb531fd0 100644
--- a/crypto/stack/stack.c
+++ b/crypto/stack/stack.c
@@ -109,6 +109,11 @@ err:
return(NULL);
}
+STACK *sk_new_null(void)
+ {
+ return sk_new((int (*)(const char * const *, const char * const *))NULL);
+ }
+
STACK *sk_new(int (*c)(const char * const *, const char * const *))
{
STACK *ret;