diff --git a/channels/h323/ast_h323.cxx b/channels/h323/ast_h323.cxx
index 21be3e64805f96f5192d5cd6d2dbcb1712224813..f574482c61013f90952f49c4bf952701bca316b1 100644
--- a/channels/h323/ast_h323.cxx
+++ b/channels/h323/ast_h323.cxx
@@ -770,9 +770,9 @@ void MyH323Connection::SetCallDetails(void *callDetails, const H323SignalPDU &se
 		unsigned plan, type, screening, presentation;
 
 		/* Fetch presentation and type information about calling party's number */
-		if (setupPDU.GetQ931().GetCallingPartyNumber(sourceName, &plan, &type, &presentation, &screening, 2, 3)) {
+		if (setupPDU.GetQ931().GetCallingPartyNumber(sourceName, &plan, &type, &presentation, &screening, 0, 0)) {
 			/* Construct fields back */
-			cd->type_of_number = (type << 4) | screening;
+			cd->type_of_number = (type << 4) | plan;
 			cd->presentation = (presentation << 5) | screening;
 		} else if (cd->call_source_e164[0]) {
 			cd->type_of_number = 0;		/* UNKNOWN */