Browse code

receive.c: logging: convert LOG to LM_*

Ovidiu Sas authored on 04/10/2014 00:59:35
Showing 1 changed files
... ...
@@ -119,7 +119,7 @@ int receive_msg(char* buf, unsigned int len, struct receive_info* rcv_info)
119 119
 
120 120
 	msg=pkg_malloc(sizeof(struct sip_msg));
121 121
 	if (msg==0) {
122
-		LOG(L_ERR, "ERROR: receive_msg: no mem for sip_msg\n");
122
+		LM_ERR("no mem for sip_msg\n");
123 123
 		goto error00;
124 124
 	}
125 125
 	msg_no++;
... ...
@@ -171,7 +171,7 @@ int receive_msg(char* buf, unsigned int len, struct receive_info* rcv_info)
171 171
 		/* sanity checks */
172 172
 		if ((msg->via1==0) || (msg->via1->error!=PARSE_OK)){
173 173
 			/* no via, send back error ? */
174
-			LOG(L_ERR, "ERROR: receive_msg: no via found in request\n");
174
+			LM_ERR("no via found in request\n");
175 175
 			STATS_BAD_MSG();
176 176
 			goto error02;
177 177
 		}
... ...
@@ -187,7 +187,7 @@ int receive_msg(char* buf, unsigned int len, struct receive_info* rcv_info)
187 187
 			){
188 188
 			if (tcpconn_add_alias(rcv_info->proto_reserved1, msg->via1->port,
189 189
 									rcv_info->proto)!=0){
190
-				LOG(L_ERR, " ERROR: receive_msg: tcp alias failed\n");
190
+				LM_ERR("tcp alias failed\n");
191 191
 				/* continue */
192 192
 			}
193 193
 		}
... ...
@@ -214,8 +214,7 @@ int receive_msg(char* buf, unsigned int len, struct receive_info* rcv_info)
214 214
 		set_route_type(REQUEST_ROUTE);
215 215
 		/* exec the routing script */
216 216
 		if (run_top_route(main_rt.rlist[DEFAULT_RT], msg, 0)<0){
217
-			LOG(L_WARN, "WARNING: receive_msg: "
218
-					"error while trying script\n");
217
+			LM_WARN("error while trying script\n");
219 218
 			goto error_req;
220 219
 		}
221 220
 
... ...
@@ -234,7 +233,7 @@ int receive_msg(char* buf, unsigned int len, struct receive_info* rcv_info)
234 233
 		/* sanity checks */
235 234
 		if ((msg->via1==0) || (msg->via1->error!=PARSE_OK)){
236 235
 			/* no via, send back error ? */
237
-			LOG(L_ERR, "ERROR: receive_msg: no via found in reply\n");
236
+			LM_ERR("no via found in reply\n");
238 237
 			STATS_BAD_RPL();
239 238
 			goto error02;
240 239
 		}
... ...
@@ -263,8 +262,7 @@ int receive_msg(char* buf, unsigned int len, struct receive_info* rcv_info)
263 262
 			ret=run_top_route(onreply_rt.rlist[DEFAULT_RT], msg, &ctx);
264 263
 #ifndef NO_ONREPLY_ROUTE_ERROR
265 264
 			if (unlikely(ret<0)){
266
-				LOG(L_WARN, "WARNING: receive_msg: "
267
-						"error while trying onreply script\n");
265
+				LM_WARN("error while trying onreply script\n");
268 266
 				goto error_rpl;
269 267
 			}else
270 268
 #endif /* NO_ONREPLY_ROUTE_ERROR */