[Spice-devel] [PATCH spice-gtk] display-gst: fix format error

Victor Toso lists at victortoso.com
Thu Jul 13 10:25:43 UTC 2017


Hi,

On Thu, Jul 13, 2017 at 12:05:40PM +0200, marcandre.lureau at redhat.com wrote:
> From: Marc-André Lureau <marcandre.lureau at redhat.com>
> 
> ../../src/channel-display-gst.c: In function 'handle_pipeline_message':
> ../../src/channel-display-gst.c:289:75: error: format '%ld' expects argument of type 'long int', but argument 2 has type 'gint64 {aka long long int}' [-Werror=format=]
>          gchar *filename = g_strdup_printf("spice-gtk-gst-pipeline-debug-%ld-%s",
>                                                                          ~~^
>                                                                          %I64d
>                                            get_stream_id_by_stream(decoder->base.stream->channel,
>                                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>                                                                    decoder->base.stream),
>                                                                    ~~~~~~~~~~~~~~~~~~~~~

oops :)

> 
> Signed-off-by: Marc-André Lureau <marcandre.lureau at redhat.com>
Acked-by: Victor Toso <victortoso at redhat.com>

> ---
>  src/channel-display-gst.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/channel-display-gst.c b/src/channel-display-gst.c
> index 3cf451b..20d236a 100644
> --- a/src/channel-display-gst.c
> +++ b/src/channel-display-gst.c
> @@ -286,7 +286,7 @@ static gboolean handle_pipeline_message(GstBus *bus, GstMessage *msg, gpointer v
>          break;
>      }
>      case GST_MESSAGE_STREAM_START: {
> -        gchar *filename = g_strdup_printf("spice-gtk-gst-pipeline-debug-%ld-%s",
> +        gchar *filename = g_strdup_printf("spice-gtk-gst-pipeline-debug-%" G_GINT64_FORMAT "-%s",
>                                            get_stream_id_by_stream(decoder->base.stream->channel,
>                                                                    decoder->base.stream),
>                                            gst_opts[decoder->base.codec_type].name);
> -- 
> 2.13.1.395.gf7b71de06
> 
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/spice-devel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/spice-devel/attachments/20170713/f29c78dd/attachment.sig>


More information about the Spice-devel mailing list