Skip to content

Commit

Permalink
fix pdo pool client
Browse files Browse the repository at this point in the history
  • Loading branch information
doubaokun committed Dec 13, 2022
1 parent 699d9f6 commit 30598aa
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions ext-src/php_swoole_library.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Generated by build-library.php, Please DO NOT modify!
*/

/* $Id: 19668965fb5df74d799cefa05913535916135160 */
/* $Id: cb70a4a2095192922ecf06f6e57cd2f1e7a5a0cb */

static const char* swoole_library_source_constants =
"\n"
Expand Down Expand Up @@ -2784,15 +2784,20 @@ static const char* swoole_library_source_core_database_pdo_pool =
" {\n"
" $this->config = $config;\n"
" parent::__construct(function () {\n"
" $driver = $this->config->getDriver();\n"
" return new PDO(\n"
" \"{$this->config->getDriver()}:\" .\n"
" \"{$driver}:\" .\n"
" (\n"
" $this->config->hasUnixSocket() ?\n"
" \"unix_socket={$this->config->getUnixSocket()};\" :\n"
" \"host={$this->config->getHost()};\" . \"port={$this->config->getPort()};\"\n"
" ) .\n"
" \"dbname={$this->config->getDbname()};\" .\n"
" \"charset={$this->config->getCharset()}\",\n"
" (\n"
" $driver !== 'pgsql' ?\n"
" \"charset={$this->config->getCharset()}\" :\n"
" ''\n"
" ),\n"
" $this->config->getUsername(),\n"
" $this->config->getPassword(),\n"
" $this->config->getOptions()\n"
Expand Down

0 comments on commit 30598aa

Please sign in to comment.