Browse code

secsipid: check version of loaded module in child init callback

Daniel-Constantin Mierla authored on 16/02/2021 15:28:31
Showing 1 changed files
... ...
@@ -134,6 +134,10 @@ static int child_init(int rank)
134 134
 	/* launch register */
135 135
 	bind_f = (secsipid_proc_bind_f)dlsym(handle, "secsipid_proc_bind");
136 136
 	if (((errstr=(char*)dlerror())==NULL) && bind_f!=NULL) {
137
+		/* version control */
138
+		if (!ksr_version_control(handle, modpath)) {
139
+			goto error;
140
+		}
137 141
 		/* no error - call it */
138 142
 		if(bind_f(&_secsipid_papi)<0) {
139 143
 			LM_ERR("filed to bind the api of proc module: %s\n", modpath);