]> gitweb.factorcode.org Git - factor.git/commitdiff
odbc: convert string to alien in odbc-prepare
authorAlexander Iljin <ajsoft@yandex.ru>
Sun, 30 Oct 2016 20:49:46 +0000 (23:49 +0300)
committerJohn Benediktsson <mrjbq7@gmail.com>
Mon, 31 Oct 2016 01:59:10 +0000 (18:59 -0700)
extra/odbc/odbc.factor

index cd621f0099711d7826e5b60ba6971b8bb50e3d2b..e13b969cbcec46792b4af5b6e3ac2a316f1151ed 100644 (file)
@@ -154,7 +154,8 @@ PRIVATE>
     SQLDisconnect succeeded? [ "odbc-disconnect failed" throw ] unless ;
 
 : odbc-prepare ( dbc string -- statement )
-    [ alloc-stmt-handle dup ] dip dup length SQLPrepare
+    [ alloc-stmt-handle dup ] dip ascii string>alien
+    dup length SQLPrepare
     succeeded? [ "odbc-prepare failed" throw ] unless ;
 
 : odbc-free-statement ( statement -- )