Module: kamailio
Branch: master
Commit: 165a3fc2e4dfed09bd9f46e43270d49cf5f72a87
URL:
https://github.com/kamailio/kamailio/commit/165a3fc2e4dfed09bd9f46e43270d49…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2015-01-23T11:07:26+01:00
permissions: init global pointer variables to null for safe shutdown at start
- reported by Olle E. Johansson, GH#41
---
Modified: modules/permissions/address.c
---
Diff:
https://github.com/kamailio/kamailio/commit/165a3fc2e4dfed09bd9f46e43270d49…
Patch:
https://github.com/kamailio/kamailio/commit/165a3fc2e4dfed09bd9f46e43270d49…
---
diff --git a/modules/permissions/address.c b/modules/permissions/address.c
index 45eecf6..7ad0fb5 100644
--- a/modules/permissions/address.c
+++ b/modules/permissions/address.c
@@ -46,17 +46,17 @@
#define TABLE_VERSION 6
-struct addr_list ***addr_hash_table; /* Ptr to current hash table ptr */
-struct addr_list **addr_hash_table_1; /* Pointer to hash table 1 */
-struct addr_list **addr_hash_table_2; /* Pointer to hash table 2 */
+struct addr_list ***addr_hash_table = NULL; /* Ptr to current hash table ptr */
+struct addr_list **addr_hash_table_1 = NULL; /* Pointer to hash table 1 */
+struct addr_list **addr_hash_table_2 = NULL; /* Pointer to hash table 2 */
-struct subnet **subnet_table; /* Ptr to current subnet table */
-struct subnet *subnet_table_1; /* Ptr to subnet table 1 */
-struct subnet *subnet_table_2; /* Ptr to subnet table 2 */
+struct subnet **subnet_table = NULL; /* Ptr to current subnet table */
+struct subnet *subnet_table_1 = NULL; /* Ptr to subnet table 1 */
+struct subnet *subnet_table_2 = NULL; /* Ptr to subnet table 2 */
-struct domain_name_list ***domain_list_table; /* Ptr to current domain name table
*/
-static struct domain_name_list **domain_list_table_1; /* Ptr to domain name table 1
*/
-static struct domain_name_list **domain_list_table_2; /* Ptr to domain name table 2
*/
+struct domain_name_list ***domain_list_table = NULL; /* Ptr to current domain name table
*/
+static struct domain_name_list **domain_list_table_1 = NULL; /* Ptr to domain name table
1 */
+static struct domain_name_list **domain_list_table_2 = NULL; /* Ptr to domain name table
2 */
static db1_con_t* db_handle = 0;