Index: libfdcore/config.c
===================================================================
--- libfdcore/config.c	(revision 1113)
+++ libfdcore/config.c	(revision 1119)
@@ -85,5 +85,5 @@
 	FD_DUMP_HANDLE_OFFSET();
 	
-	CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, "freeDiameter configuration:\n", fd_g_config), return NULL);	
+	CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, "freeDiameter configuration:\n"), return NULL);	
 	CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, "  Default trace level .... : %+d\n", fd_g_debug_lvl), return NULL);
 	CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, "  Configuration file ..... : %s\n", fd_g_config->cnf_file), return NULL);
Index: libfdcore/core.c
===================================================================
--- libfdcore/core.c	(revision 1112)
+++ libfdcore/core.c	(revision 1119)
@@ -320,5 +320,4 @@
 int fd_core_wait_shutdown_complete(void)
 {
-	int ret;
 	enum core_state cur_state = core_state_get();
 	void * th_ret = NULL;
Index: libfdcore/endpoints.c
===================================================================
--- libfdcore/endpoints.c	(revision 1113)
+++ libfdcore/endpoints.c	(revision 1119)
@@ -328,4 +328,5 @@
 		}
 	}
-}
-	
+	return *buf;
+}
+	
Index: libfdcore/p_ce.c
===================================================================
--- libfdcore/p_ce.c	(revision 1113)
+++ libfdcore/p_ce.c	(revision 1119)
@@ -275,6 +275,5 @@
 		if (hdr->avp_flags & AVP_FLAG_VENDOR) {
 			/* Ignore all vendor-specific AVPs in CER/CEA because we don't support any currently */
-			TRACE_DEBUG(FULL, "Ignored a vendor AVP in CER / CEA");
-			fd_msg_dump_one(FULL, avp);
+			LOG_A("Ignored a vendor-specific AVP in CER / CEA");
 			goto next;
 		}
@@ -284,6 +283,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -297,6 +295,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -319,6 +316,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -350,6 +346,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -376,6 +371,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -397,6 +391,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -419,6 +412,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -440,6 +432,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -468,6 +459,5 @@
 
 						if (inhdr->avp_flags & AVP_FLAG_VENDOR) {
-							TRACE_DEBUG(FULL, "Ignored a vendor AVP inside Vendor-Specific-Application-Id AVP");
-							fd_msg_dump_one(FULL, avp);
+							LOG_A("Ignored a vendor AVP inside Vendor-Specific-Application-Id AVP");
 							goto innext;
 						}
@@ -475,6 +465,5 @@
 						if (inhdr->avp_value == NULL) {
 							/* This is a sanity check */
-							TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-							fd_msg_dump_one(NONE, avp);
+							LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 							ASSERT(0); /* To check if this really happens, and understand why... */
 							goto innext;
@@ -508,6 +497,5 @@
 						
 						if (invalid) {
-							TRACE_DEBUG(FULL, "Invalid Vendor-Specific-Application-Id AVP received, ignored");
-							fd_msg_dump_one(FULL, avp);
+							TRACE_DEBUG(FULL, "Invalid Vendor-Specific-Application-Id AVP received");
 							error->pei_errcode = "DIAMETER_INVALID_AVP_VALUE";
 							error->pei_avp = avp;
@@ -533,6 +521,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -549,6 +536,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -566,6 +552,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
@@ -578,6 +563,5 @@
 				if (hdr->avp_value == NULL) {
 					/* This is a sanity check */
-					TRACE_DEBUG(NONE, "Ignored an AVP with unset value in CER/CEA");
-					fd_msg_dump_one(NONE, avp);
+					LOG_F("Ignored an AVP (code %x) with unset value in CER/CEA", hdr->avp_code);
 					ASSERT(0); /* To check if this really happens, and understand why... */
 					goto next;
Index: libfdcore/p_dp.c
===================================================================
--- libfdcore/p_dp.c	(revision 1010)
+++ libfdcore/p_dp.c	(revision 1119)
@@ -76,6 +76,5 @@
 			if (hdr->avp_value == NULL) {
 				/* This is a sanity check */
-				TRACE_DEBUG(NONE, "BUG: Unset value in Disconnect-Cause in DPR");
-				fd_msg_dump_one(NONE, dc);
+				LOG_F("BUG: Unset value in Disconnect-Cause in DPR");
 				ASSERT(0); /* To check if this really happens, and understand why... */
 			}
Index: libfdcore/p_dw.c
===================================================================
--- libfdcore/p_dw.c	(revision 974)
+++ libfdcore/p_dw.c	(revision 1119)
@@ -51,6 +51,5 @@
 		if (hdr->avp_value == NULL) {
 			/* This is a sanity check */
-			TRACE_DEBUG(NONE, "BUG: Unset value in Origin-State-Id in DWR / DWA");
-			fd_msg_dump_one(NONE, osi);
+			LOG_F("Ignored an Origin-State-Id AVP with unset value in DWR/DWA");
 			ASSERT(0); /* To check if this really happens, and understand why... */
 		}
Index: libfdcore/p_out.c
===================================================================
--- libfdcore/p_out.c	(revision 1113)
+++ libfdcore/p_out.c	(revision 1119)
@@ -132,5 +132,5 @@
 				if (msg) {
 					char buf[256];
-					snprintf(buf, sizeof(buf), "Error while sending this message: s", strerror(ret));
+					snprintf(buf, sizeof(buf), "Error while sending this message: %s", strerror(ret));
 					fd_hook_call(HOOK_MESSAGE_DROPPED, msg, NULL, buf, fd_msg_pmdl_get(msg));
 					fd_msg_free(msg);
@@ -186,5 +186,5 @@
 				if (msg) {
 					char buf[256];
-					snprintf(buf, sizeof(buf), "Error while sending this message: s", strerror(ret));
+					snprintf(buf, sizeof(buf), "Error while sending this message: %s", strerror(ret));
 					fd_hook_call(HOOK_MESSAGE_DROPPED, *msg, NULL, buf, fd_msg_pmdl_get(*msg));
 					fd_msg_free(*msg);
Index: libfdcore/p_sr.c
===================================================================
--- libfdcore/p_sr.c	(revision 1113)
+++ libfdcore/p_sr.c	(revision 1119)
@@ -80,6 +80,4 @@
 			(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)),
 			(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)));
-		
-		fd_msg_dump_one(ANNOYING + 1, sr->req);
 	}
 }
Index: libfdcore/routing_dispatch.c
===================================================================
--- libfdcore/routing_dispatch.c	(revision 1113)
+++ libfdcore/routing_dispatch.c	(revision 1119)
@@ -429,5 +429,5 @@
 {
 	struct msg_hdr * hdr;
-	int is_req = 0, ret;
+	int is_req = 0;
 	struct session * sess;
 	enum disp_action action;
@@ -1079,8 +1079,5 @@
 		}
 		
-		if (TRACE_BOOL(FULL)) {
-			TRACE_DEBUG(FULL, "Picked next message (%s)", action_name);
-			fd_msg_dump_one(ANNOYING, msg);
-		}
+		LOG_A("%s: Picked next message", action_name);
 
 		/* Now process the message */
