protect against crashes in bad user code

This commit is contained in:
Vítor Santos Costa 2015-03-11 22:23:31 +00:00
parent 04ff7f3f2d
commit 7cceb655b3
3 changed files with 6 additions and 5 deletions

View File

@ -275,6 +275,7 @@ filter(StreamInp, StreamOut, Command) :-
! !
; ;
call(Command, Line, NewLine), call(Command, Line, NewLine),
ground(NewLine),
format(StreamOut, '~s~n', [NewLine]), format(StreamOut, '~s~n', [NewLine]),
fail fail
). ).

@ -1 +1 @@
Subproject commit 8257467ff9a7bb901d1688e6a75ad072e0246aba Subproject commit ac9806399b2484b91507df6973808d8f8027c157

View File

@ -870,7 +870,7 @@ You can see the available SQL Modes at the MySQL homepage at
% db_open/4 % db_open/4
% %
#if MYDDAS_DECLARATIONS #if 1 // MYDDAS_DECLARATIONS
:- db_open(Protocol) extra_arguments :- db_open(Protocol) extra_arguments
db=Db, db=Db,
port=Port, port=Port,
@ -904,7 +904,7 @@ atom(X) ==> nonvar(X),
\+ atom(X) * nonvar(X) ==> error(atom, X), \+ atom(X) * nonvar(X) ==> error(atom, X),
var(X) ==> error(var, X), var(X) ==> error(var, X),
internet_host(X) <=> atom(X), internet_host(X) == atom(X),
integer(X) ==> nonvar(X), integer(X) ==> nonvar(X),
\+ integer(X) * nonvar(X) ==> error(integer, X), \+ integer(X) * nonvar(X) ==> error(integer, X),
@ -976,7 +976,7 @@ c^c_db_odbc_connect(ODBCEntry,User,Password,Handle) ),
/* /*
( c^c_db_my_connect(Host,User,Password,Db,Port,Socket,Handle) == ( c^c_db_my_connect(Host,User,Password,Db,Port,Socket,Handle) ==
-(Protocol = odbc)* Protocol = odbc
(Protocol = mysql) * (Protocol = mysql) *
-(Protocol = sqlite3)* -(Protocol = sqlite3)*
-(Protocol = postgres) ), -(Protocol = postgres) ),