]> gitweb.factorcode.org Git - factor.git/commitdiff
openssl.libcrypto.tests: BIO_free should be called to release connections
authorBjörn Lindqvist <bjourne@gmail.com>
Tue, 23 Sep 2014 22:45:46 +0000 (00:45 +0200)
committerJohn Benediktsson <mrjbq7@gmail.com>
Fri, 3 Oct 2014 14:12:27 +0000 (07:12 -0700)
basis/openssl/libcrypto/libcrypto-tests.factor

index 0a896db51139100764d3bcf59a009a5ea937f22d..92b8dcc39faf83b2e29fd71f788fb91a84292a53 100644 (file)
@@ -10,15 +10,18 @@ IN: openssl.libcrypto.tests
 
 [ t ] [ "factorcode.org:80" BIO_new_connect bio_st? ] unit-test
 
-[ 1 ] [
-    "factorcode.org:80" BIO_new_connect BIO_C_DO_STATE_MACHINE 0 f BIO_ctrl
+[ 1 1 ] [
+    "factorcode.org:80" BIO_new_connect [
+        BIO_C_DO_STATE_MACHINE 0 f BIO_ctrl
+    ] keep BIO_free
 ] unit-test
 
-[ "HTTP/1.1 200 Document follows" ] [
-    "factorcode.org:80" BIO_new_connect
-    [ BIO_C_DO_STATE_MACHINE 0 f BIO_ctrl drop ]
-    [
-        [ "GET / HTTP/1.1\r\nHost: factorcode.org\r\n\r\n" BIO_puts drop ]
-        [ 1024 <byte-array> dup swapd 1023 BIO_read drop ] bi
-    ] bi >string "\r\n" split first
+[ "HTTP/1.1 200 Document follows" 1 ] [
+    "factorcode.org:80" BIO_new_connect [
+        [ BIO_C_DO_STATE_MACHINE 0 f BIO_ctrl drop ]
+        [
+            [ "GET / HTTP/1.1\r\nHost: factorcode.org\r\n\r\n" BIO_puts drop ]
+            [ 1024 <byte-array> dup swapd 1023 BIO_read drop ] bi
+        ] bi >string "\r\n" split first
+    ] keep BIO_free
 ] unit-test