pike.git / lib / modules / Sql.pmod / pgsql_util.pmod

version» Context lines:

pike.git/lib/modules/Sql.pmod/pgsql_util.pmod:346:    error(strerror(socket->errno()));    socket->set_backend(local_backend);    socket->set_buffer_mode(i::this,0);    socket->set_nonblocking(read_cb,write_cb,0);    Thread.Thread(pgsqlsess->_processloop,this);    return;    };    pgsqlsess->_connectfail(err);    }    +  private string _sprintf(int type, void|mapping flags) { +  string res=UNDEFINED; +  switch(type) { +  case 'O': +  res=predef::sprintf("PGassist fd: %d input queue: %d/%d " +  "queued portals: %d output queue: %d/%d\n", +  socket&&socket->query_fd(), +  sizeof(i::this),i::_size_object(), +  qportals->size(),sizeof(this),_size_object()); +  break; +  } +  return res; +  } +     protected void create(object _pgsqlsess,Thread.Queue _qportals,int nossl) {    i::create(); o::create();    qportals = _qportals;    synctransact = 1;    fillread=Thread.Condition();    fillreadmux=Thread.Mutex();    gottimeout=sendcmd; // Preset it with a NOP    timeout=128; // Just a reasonable amount    socket=Stdio.File();    nostash=Thread.Mutex();