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

version» Context lines:

pike.git/lib/modules/Sql.pmod/pgsql.pike:1208:    showportalstack("THROWN");   #endif    if(objectp(portal))    portal->_releasesession();    portal=0;    if(!waitforauthready)    continue; // Only continue if authentication did not fail    }    break;    } -  PD("Closing database processloop %O\n",err); +  PD("Closing database processloop %s\n", err ? describe_backtrace(err) : "");    _delayederror=err;    if (objectp(portal)) {   #ifdef PG_DEBUG    showportal(0);   #endif    portal->_purgeportal();    }    if(!terminating && _options.reconnect)    _connectfail();    else    destruct(waitforauthready);    termlock=0;    if(err && !stringp(err))    throw(err);    };    if (err) {    unnamedstatement=0;    termlock = 0; -  throw(err); +  PD("Terminating processloop due to %s\n", describe_backtrace(err));    }   }      //! Closes the connection to the database, any running queries are   //! terminated instantly.   //!   //! @note   //! This function is PostgreSQL-specific, and thus it is not available   //! through the generic SQL-interface.   /*semi*/final void close() {    throwdelayederror(this);    Thread.MutexKey lock;    if (qportals && qportals->size())    catch(cancelquery());    if (unnamedstatement)    termlock = unnamedstatement->lock(1); -  +  if (c) // Prevent trivial backtraces    c->close();    if (unnamedstatement)    lock = unnamedstatement->lock(1); -  +  if (c)    destruct(c);    lock = 0;    destruct(waitforauthready);   }      protected void destroy() {    string errstring;    mixed err = catch(close());    .pgsql_util.unregister_backend();    /*