[patch] make dbus-monitor "classic output" and other dbus-print-message users print the reply serials on replies

Olli Salli olli.salli at collabora.co.uk
Fri Feb 2 04:13:05 PST 2007


Olli Salli wrote:
> Greetings list,
> 
> while I was basking in the glory of finally being able to see method returns and errors with dbus-monitor, a colleague of mine pointed out that dbus-monitor doesn't actually print anything associating method calls and returns.
> 
> This patch adds printing of the reply serial to method returns and errors, so you can actually figure out the message/reply pairs.
> 
> Olli
> 
> 
> ------------------------------------------------------------------------
> 
> Index: tools/dbus-print-message.c
> ===================================================================
> RCS file: /cvs/dbus/dbus/tools/dbus-print-message.c,v
> retrieving revision 1.12
> diff -u -p -r1.12 dbus-print-message.c
> --- tools/dbus-print-message.c	14 Jun 2006 11:26:41 -0000	1.12
> +++ tools/dbus-print-message.c	10 Nov 2006 12:29:43 -0000
> @@ -270,12 +270,14 @@ print_message (DBusMessage *message, dbu
>  	  break;
>        
>  	case DBUS_MESSAGE_TYPE_METHOD_RETURN:
> -	  printf ("\n");
> +	  printf (" reply_serial=%u\n",
> +          dbus_message_get_reply_serial (message));
>  	  break;
>  
>  	case DBUS_MESSAGE_TYPE_ERROR:
> -	  printf (" error_name=%s\n",
> -		  dbus_message_get_error_name (message));
> +	  printf (" error_name=%s reply_serial=%u\n",
> +		  dbus_message_get_error_name (message),
> +          dbus_message_get_reply_serial (message));
>  	  break;
>  
>  	default:
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> dbus mailing list
> dbus at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dbus

Hi,

I see this still hasn't been merged. Something wrong with the patch?

Olli Salli


More information about the dbus mailing list