Browse code

core - tm: improved log messages

- udp_send() prints outgoing buffer len as unsigned
- build_uac_req() prints the size of attempted memory chunk allocation

Daniel-Constantin Mierla authored on 23/04/2010 14:44:49
Showing 2 changed files
... ...
@@ -1368,7 +1368,7 @@ char* build_uac_req(str* method, str* headers, str* body, dlg_t* dialog, int bra
1368 1368
 
1369 1369
 	buf = shm_malloc(*len + 1);
1370 1370
 	if (!buf) {
1371
-		LOG(L_ERR, "build_uac_req(): no shmem\n");
1371
+		LOG(L_ERR, "build_uac_req(): no shmem (%d)\n", *len);
1372 1372
 		goto error;
1373 1373
 	}
1374 1374
 	
... ...
@@ -568,7 +568,7 @@ again:
568 568
 #endif
569 569
 	if (n==-1){
570 570
 		su2ip_addr(&ip, &dst->to);
571
-		LOG(L_ERR, "ERROR: udp_send: sendto(sock,%p,%d,0,%s:%d,%d): %s(%d)\n",
571
+		LOG(L_ERR, "ERROR: udp_send: sendto(sock,%p,%u,0,%s:%d,%d): %s(%d)\n",
572 572
 				buf,len, ip_addr2a(&ip), su_getport(&dst->to), tolen,
573 573
 				strerror(errno),errno);
574 574
 		if (errno==EINTR) goto again;