Module: sip-router
Branch: master
Commit: f3e18e3885eff64d5808ede28a12210a4ad4ae19
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=f3e18e3…
Author: Juha Heinanen <jh(a)tutpro.com>
Committer: Juha Heinanen <jh(a)tutpro.com>
Date: Tue Jun 9 15:54:42 2009 +0300
* Closed database connection after two error case. Thanks to Jan for
pointing out the bug.
---
modules/lcr/lcr_mod.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/modules/lcr/lcr_mod.c b/modules/lcr/lcr_mod.c
index 52e2cf5..6743a21 100644
--- a/modules/lcr/lcr_mod.c
+++ b/modules/lcr/lcr_mod.c
@@ -1052,6 +1052,7 @@ int reload_gws_and_lcrs(void)
}
if (lcr_dbf.use_table(dbh, &gw_table) < 0) {
+ lcr_dbf.close(dbh);
LM_ERR("error while trying to use gw table\n");
return -1;
}
@@ -1273,6 +1274,7 @@ int reload_gws_and_lcrs(void)
}
if (lcr_dbf.use_table(dbh, &lcr_table) < 0) {
+ lcr_dbf.close(dbh);
LM_ERR("error while trying to use lcr table\n");
return -1;
}