[Spice-commits] 2 commits - AUTHORS server/gstreamer-encoder.c server/main-channel.cpp

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Sat Jan 29 16:26:53 UTC 2022


 AUTHORS                    |    1 +
 server/gstreamer-encoder.c |    2 +-
 server/main-channel.cpp    |    2 ++
 3 files changed, 4 insertions(+), 1 deletion(-)

New commits:
commit b24e2ea68e34a1b00298d818af594f656d4bdf47
Author: Frediano Ziglio <freddy77 at gmail.com>
Date:   Wed Nov 10 14:21:08 2021 +0000

    ci: Fix compile error using new GStreamer library
    
    Using Fedora 35 the compilation fails due to this warning:
    
        ../server/gstreamer-encoder.c: In function 'create_pipeline':
        ../server/gstreamer-encoder.c:994:5: error: braces around scalar initializer [-Werror]
         994 |     GstAppSinkCallbacks appsink_cbs = {NULL, NULL, &new_sample, {NULL}};
             |     ^~~~~~~~~~~~~~~~~~~
        ../server/gstreamer-encoder.c:994:5: note: (near initialization for 'appsink_cbs.new_event')
        ../server/gstreamer-encoder.c:994:5: error: missing initializer for field '_gst_reserved' of 'GstAppSinkCallbacks' [-Werror=missing-field-initializers]
        In file included from ../server/gstreamer-encoder.c:26:
        /usr/include/gstreamer-1.0/gst/app/gstappsink.h:81:16: note: '_gst_reserved' declared here
           81 |   gpointer     _gst_reserved[GST_PADDING - 1];
              |                ^~~~~~~~~~~~~
        cc1: all warnings being treated as errors
    
    Change structure initialisation to avoid the warning.
    The same syntax is already used in server/tests/test-gst.cpp.
    
    Signed-off-by: Frediano Ziglio <freddy77 at gmail.com>

diff --git a/server/gstreamer-encoder.c b/server/gstreamer-encoder.c
index 973a5f3f..5ea11f4b 100644
--- a/server/gstreamer-encoder.c
+++ b/server/gstreamer-encoder.c
@@ -991,7 +991,7 @@ static gboolean create_pipeline(SpiceGstEncoder *encoder)
 #ifdef HAVE_GSTREAMER_0_10
     GstAppSinkCallbacks appsink_cbs = {NULL, NULL, &new_sample, NULL, {NULL}};
 #else
-    GstAppSinkCallbacks appsink_cbs = {NULL, NULL, &new_sample, {NULL}};
+    GstAppSinkCallbacks appsink_cbs = {NULL, NULL, &new_sample, ._gst_reserved={NULL}};
 #endif
     gst_app_sink_set_callbacks(encoder->appsink, &appsink_cbs, encoder, NULL);
 
commit cf061597b63b5641af9b98b762afdec8514338b0
Author: Geoffrey McRae <geoff at hostfission.com>
Date:   Tue Jan 4 07:53:17 2022 +0000

    Report name/uuid and agent connected tokens support.
    
    A well behaved client implementing the SPICE protocol should check to see
    if the server supports the capabilities it needs. This implementation of
    the spice-server supports `SPICE_MAIN_CAP_NAME_AND_UUID` and `
    SPICE_MAIN_CAP_AGENT_CONNECTED_TOKENS` so it should report this to the
    client.
    
    Acked-by: Frediano Ziglio <freddy77 at gmail.com>

diff --git a/AUTHORS b/AUTHORS
index a28cdb62..17979475 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -85,5 +85,6 @@ Patches also contributed by
     Qiuhao Li <Qiuhao.Li at outlook.com>
     Hunter Sezen <orbea at riseup.net>
     Simon Chopin <simon.chopin at canonical.com>
+    Geoffrey McRae <geoff at hostfission.com>
 
    ....send patches to get your name here...
diff --git a/server/main-channel.cpp b/server/main-channel.cpp
index 41716aba..e14a45d5 100644
--- a/server/main-channel.cpp
+++ b/server/main-channel.cpp
@@ -218,6 +218,8 @@ MainChannel::MainChannel(RedsState *reds):
     RedChannel(reds, SPICE_CHANNEL_MAIN, 0, RedChannel::MigrateAll)
 {
     set_cap(SPICE_MAIN_CAP_SEMI_SEAMLESS_MIGRATE);
+    set_cap(SPICE_MAIN_CAP_NAME_AND_UUID);
+    set_cap(SPICE_MAIN_CAP_AGENT_CONNECTED_TOKENS);
     set_cap(SPICE_MAIN_CAP_SEAMLESS_MIGRATE);
 }
 


More information about the Spice-commits mailing list