Changeset 1119:79dd22145f52 in freeDiameter for libfdcore
- Timestamp:
- May 14, 2013, 12:04:20 PM (11 years ago)
- Branch:
- default
- Phase:
- public
- Location:
- libfdcore
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
libfdcore/config.c
r1113 r1119 85 85 FD_DUMP_HANDLE_OFFSET(); 86 86 87 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, "freeDiameter configuration:\n" , fd_g_config), return NULL);87 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, "freeDiameter configuration:\n"), return NULL); 88 88 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, " Default trace level .... : %+d\n", fd_g_debug_lvl), return NULL); 89 89 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, " Configuration file ..... : %s\n", fd_g_config->cnf_file), return NULL); -
libfdcore/core.c
r1112 r1119 320 320 int fd_core_wait_shutdown_complete(void) 321 321 { 322 int ret;323 322 enum core_state cur_state = core_state_get(); 324 323 void * th_ret = NULL; -
libfdcore/endpoints.c
r1113 r1119 328 328 } 329 329 } 330 } 331 330 return *buf; 331 } 332 -
libfdcore/p_ce.c
r1113 r1119 275 275 if (hdr->avp_flags & AVP_FLAG_VENDOR) { 276 276 /* Ignore all vendor-specific AVPs in CER/CEA because we don't support any currently */ 277 TRACE_DEBUG(FULL, "Ignored a vendor AVP in CER / CEA"); 278 fd_msg_dump_one(FULL, avp); 277 LOG_A("Ignored a vendor-specific AVP in CER / CEA"); 279 278 goto next; 280 279 } … … 284 283 if (hdr->avp_value == NULL) { 285 284 /* This is a sanity check */ 286 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 287 fd_msg_dump_one(NONE, avp); 285 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 288 286 ASSERT(0); /* To check if this really happens, and understand why... */ 289 287 goto next; … … 297 295 if (hdr->avp_value == NULL) { 298 296 /* This is a sanity check */ 299 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 300 fd_msg_dump_one(NONE, avp); 297 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 301 298 ASSERT(0); /* To check if this really happens, and understand why... */ 302 299 goto next; … … 319 316 if (hdr->avp_value == NULL) { 320 317 /* This is a sanity check */ 321 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 322 fd_msg_dump_one(NONE, avp); 318 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 323 319 ASSERT(0); /* To check if this really happens, and understand why... */ 324 320 goto next; … … 350 346 if (hdr->avp_value == NULL) { 351 347 /* This is a sanity check */ 352 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 353 fd_msg_dump_one(NONE, avp); 348 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 354 349 ASSERT(0); /* To check if this really happens, and understand why... */ 355 350 goto next; … … 376 371 if (hdr->avp_value == NULL) { 377 372 /* This is a sanity check */ 378 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 379 fd_msg_dump_one(NONE, avp); 373 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 380 374 ASSERT(0); /* To check if this really happens, and understand why... */ 381 375 goto next; … … 397 391 if (hdr->avp_value == NULL) { 398 392 /* This is a sanity check */ 399 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 400 fd_msg_dump_one(NONE, avp); 393 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 401 394 ASSERT(0); /* To check if this really happens, and understand why... */ 402 395 goto next; … … 419 412 if (hdr->avp_value == NULL) { 420 413 /* This is a sanity check */ 421 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 422 fd_msg_dump_one(NONE, avp); 414 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 423 415 ASSERT(0); /* To check if this really happens, and understand why... */ 424 416 goto next; … … 440 432 if (hdr->avp_value == NULL) { 441 433 /* This is a sanity check */ 442 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 443 fd_msg_dump_one(NONE, avp); 434 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 444 435 ASSERT(0); /* To check if this really happens, and understand why... */ 445 436 goto next; … … 468 459 469 460 if (inhdr->avp_flags & AVP_FLAG_VENDOR) { 470 TRACE_DEBUG(FULL, "Ignored a vendor AVP inside Vendor-Specific-Application-Id AVP"); 471 fd_msg_dump_one(FULL, avp); 461 LOG_A("Ignored a vendor AVP inside Vendor-Specific-Application-Id AVP"); 472 462 goto innext; 473 463 } … … 475 465 if (inhdr->avp_value == NULL) { 476 466 /* This is a sanity check */ 477 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 478 fd_msg_dump_one(NONE, avp); 467 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 479 468 ASSERT(0); /* To check if this really happens, and understand why... */ 480 469 goto innext; … … 508 497 509 498 if (invalid) { 510 TRACE_DEBUG(FULL, "Invalid Vendor-Specific-Application-Id AVP received, ignored"); 511 fd_msg_dump_one(FULL, avp); 499 TRACE_DEBUG(FULL, "Invalid Vendor-Specific-Application-Id AVP received"); 512 500 error->pei_errcode = "DIAMETER_INVALID_AVP_VALUE"; 513 501 error->pei_avp = avp; … … 533 521 if (hdr->avp_value == NULL) { 534 522 /* This is a sanity check */ 535 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 536 fd_msg_dump_one(NONE, avp); 523 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 537 524 ASSERT(0); /* To check if this really happens, and understand why... */ 538 525 goto next; … … 549 536 if (hdr->avp_value == NULL) { 550 537 /* This is a sanity check */ 551 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 552 fd_msg_dump_one(NONE, avp); 538 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 553 539 ASSERT(0); /* To check if this really happens, and understand why... */ 554 540 goto next; … … 566 552 if (hdr->avp_value == NULL) { 567 553 /* This is a sanity check */ 568 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 569 fd_msg_dump_one(NONE, avp); 554 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 570 555 ASSERT(0); /* To check if this really happens, and understand why... */ 571 556 goto next; … … 578 563 if (hdr->avp_value == NULL) { 579 564 /* This is a sanity check */ 580 TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA"); 581 fd_msg_dump_one(NONE, avp); 565 LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code); 582 566 ASSERT(0); /* To check if this really happens, and understand why... */ 583 567 goto next; -
libfdcore/p_dp.c
r1010 r1119 76 76 if (hdr->avp_value == NULL) { 77 77 /* This is a sanity check */ 78 TRACE_DEBUG(NONE, "BUG: Unset value in Disconnect-Cause in DPR"); 79 fd_msg_dump_one(NONE, dc); 78 LOG_F("BUG: Unset value in Disconnect-Cause in DPR"); 80 79 ASSERT(0); /* To check if this really happens, and understand why... */ 81 80 } -
libfdcore/p_dw.c
r974 r1119 51 51 if (hdr->avp_value == NULL) { 52 52 /* This is a sanity check */ 53 TRACE_DEBUG(NONE, "BUG: Unset value in Origin-State-Id in DWR / DWA"); 54 fd_msg_dump_one(NONE, osi); 53 LOG_F("Ignored an Origin-State-Id AVP with unset value in DWR/DWA"); 55 54 ASSERT(0); /* To check if this really happens, and understand why... */ 56 55 } -
libfdcore/p_out.c
r1113 r1119 132 132 if (msg) { 133 133 char buf[256]; 134 snprintf(buf, sizeof(buf), "Error while sending this message: s", strerror(ret));134 snprintf(buf, sizeof(buf), "Error while sending this message: %s", strerror(ret)); 135 135 fd_hook_call(HOOK_MESSAGE_DROPPED, msg, NULL, buf, fd_msg_pmdl_get(msg)); 136 136 fd_msg_free(msg); … … 186 186 if (msg) { 187 187 char buf[256]; 188 snprintf(buf, sizeof(buf), "Error while sending this message: s", strerror(ret));188 snprintf(buf, sizeof(buf), "Error while sending this message: %s", strerror(ret)); 189 189 fd_hook_call(HOOK_MESSAGE_DROPPED, *msg, NULL, buf, fd_msg_pmdl_get(*msg)); 190 190 fd_msg_free(*msg); -
libfdcore/p_sr.c
r1113 r1119 80 80 (long)((now.tv_nsec >= sr->added_on.tv_nsec) ? (now.tv_sec - sr->added_on.tv_sec) : (now.tv_sec - sr->added_on.tv_sec - 1)), 81 81 (long)((now.tv_nsec >= sr->added_on.tv_nsec) ? ((now.tv_nsec - sr->added_on.tv_nsec) / 1000) : ((now.tv_nsec - sr->added_on.tv_nsec + 1000000000) / 1000))); 82 83 fd_msg_dump_one(ANNOYING + 1, sr->req);84 82 } 85 83 } -
libfdcore/routing_dispatch.c
r1113 r1119 429 429 { 430 430 struct msg_hdr * hdr; 431 int is_req = 0 , ret;431 int is_req = 0; 432 432 struct session * sess; 433 433 enum disp_action action; … … 1079 1079 } 1080 1080 1081 if (TRACE_BOOL(FULL)) { 1082 TRACE_DEBUG(FULL, "Picked next message (%s)", action_name); 1083 fd_msg_dump_one(ANNOYING, msg); 1084 } 1081 LOG_A("%s: Picked next message", action_name); 1085 1082 1086 1083 /* Now process the message */
Note: See TracChangeset
for help on using the changeset viewer.