pike.git/
lib/
modules/
Sql.pmod/
pgsql_util.pmod
Branch:
Tag:
Non-build tags
All tags
No tags
2017-11-20
2017-11-20 23:48:05 by Stephen R. van den Berg <srb@cuci.nl>
4b055c05a325a2cffd16806bceb5cc32b47b5b38 (
12
lines) (+
4
/-
8
)
[
Show
|
Annotate
]
Branch:
8.1
pgsql: Eliminate connectfail() backreferences.
290:
private int closenext; final sfile socket;
-
private function(void|mixed:void) connectfail;
+
private int towrite; final multiset(function(void|mixed:void)) closecallbacks=(<>);
413:
return; }; lock=0;
-
catch
(
connectfail(
)
)
;
+
destruct
(
this
);
} final int close() {
450:
socket->close(); }; }
-
catch(connectfail = 0);
+
} final void connectloop(object pgsqlsess, int nossl) {
489:
#endif break; }
-
connectfail=pgsqlsess->_connectfail;
+
if(!socket->is_open()) error(strerror(socket->errno())+".\n"); socket->set_backend(local_backend); socket->set_buffer_mode(i,0); socket->set_nonblocking(i->read_cb,write_cb,close);
-
if (nossl != 2)
{
-
connectfail=pgsqlsess->_connectfail;
+
if (nossl != 2)
Thread.Thread(pgsqlsess->_processloop,this);
-
}
+
return; };
-
catch
(
connectfail(err
)
)
;
+
destruct
(
this
);
} private string _sprintf(int type) {