Browse code

textops: remove check done in the called function

Daniel-Constantin Mierla authored on 02/11/2019 17:04:23
Showing 1 changed files
... ...
@@ -177,11 +177,6 @@ static int ki_msg_set_buffer(sip_msg_t *msg, str *obuf)
177 177
  */
178 178
 static int ki_msg_apply_changes(sip_msg_t *msg)
179 179
 {
180
-	if(msg->first_line.type != SIP_REPLY && get_route_type() != REQUEST_ROUTE) {
181
-		LM_ERR("invalid usage - not in request route or a reply\n");
182
-		return -1;
183
-	}
184
-
185 180
 	return sip_msg_apply_changes(msg);
186 181
 }
187 182
 
... ...
@@ -190,7 +185,7 @@ static int ki_msg_apply_changes(sip_msg_t *msg)
190 190
  */
191 191
 static int msg_apply_changes_f(sip_msg_t *msg, char *str1, char *str2)
192 192
 {
193
-	return ki_msg_apply_changes(msg);
193
+	return sip_msg_apply_changes(msg);
194 194
 }
195 195
 
196 196
 /**