pike.git/
lib/
modules/
Sql.pmod/
pgsql_util.pmod
Branch:
Tag:
Non-build tags
All tags
No tags
2016-10-15
2016-10-15 09:35:12 by Stephen R. van den Berg <srb@cuci.nl>
c4abb08b4696d4ab1a0e2143ef4a8c71ec5aa7b2 (
16
lines) (+
8
/-
8
)
[
Show
|
Annotate
]
Branch:
8.0
pgsql: Cater for callbacks waiting for mutex while being destructed.
284:
private int write_cb() { Thread.MutexKey lock = shortmux->lock();
-
towrite -= output_to(socket,towrite);
+
if (this) {
+
towrite -= output_to(socket,
towrite);
lock = 0;
-
#ifdef PG_DEBUG
-
if (!i->fillread)
-
PD("%d>Delayed close to go %d\n", socket->query_fd(), sizeof(this));
-
#endif
+
if (!i->fillread && !sizeof(this)) close();
-
+
} else
+
lock = 0;
return 0; }