]> git.ipfire.org Git - thirdparty/asterisk.git/commit
Fix reconnecting to pgsql database after connection loss.
authorRichard Mudgett <rmudgett@digium.com>
Mon, 13 Feb 2012 17:24:01 +0000 (17:24 +0000)
committerRichard Mudgett <rmudgett@digium.com>
Mon, 13 Feb 2012 17:24:01 +0000 (17:24 +0000)
commit5f34afae142b424c9a80bcdf9dfab9b0d36c7bde
tree8047e614d1d7847e94ab7c670c9baea401d99ee3
parent6dde382e1dc22fea6030b577535cf499b9c8a2e6
Fix reconnecting to pgsql database after connection loss.

There can only be one database connection in res_config_pgsql just like
res_config_sqlite.  If the connection is lost, the connection may not get
reestablished to the same database if the res_pgsql.conf and
extconfig.conf files are inconsistent.

* Made only use the configured database from res_pgsql.conf.

* Fixed potential buffer overwrite of last[] in config_pgsql().

(closes issue ASTERISK-16982)
Reported by: german aracil boned

Review: https://reviewboard.asterisk.org/r/1731/
........

Merged revisions 354953 from http://svn.asterisk.org/svn/asterisk/branches/1.8

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/10@354959 65c4cc65-6c06-0410-ace0-fbb531ad65f3
configs/extconfig.conf.sample
res/res_config_pgsql.c