Browse Source

Reset vars when reusing a persistent connection as requested from postgres developers

PEAR_1_4DEV
Marcus Boerger 23 years ago
parent
commit
6175f0a4c9
  1. 5
      ext/pgsql/pgsql.c

5
ext/pgsql/pgsql.c

@ -624,6 +624,11 @@ static void php_pgsql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent)
goto err;
}
}
if (atof(PG_VERSION) >= 7.2) {
PGresult *pg_result;
pg_result = PQexec(le->ptr, "RESET ALL");
PQclear(pg_result);
}
pgsql = (PGconn *) le->ptr;
}
ZEND_REGISTER_RESOURCE(return_value, pgsql, le_plink);

Loading…
Cancel
Save