[Spice-devel] [PATCH 3/7] Move InputsChannelClient to a separate file

2016-05-20 Thread Jonathon Jongsma
Preparation for converting to GObject --- server/Makefile.am | 2 + server/inputs-channel-client.c | 87 ++ server/inputs-channel-client.h | 48 +++ server/inputs-channel.c| 80 +++---

[Spice-devel] [PATCH 7/7] Limit direct access to DisplayChannelClient

2016-05-20 Thread Jonathon Jongsma
Add a few more methods and accessors so that other files don't need to manipulate the struct members directly. Move the struct definition to a private header which only the dcc-* files will include. --- server/Makefile.am | 1 + server/dcc-encoders.c| 11 +++--- server/dcc-encoders.h

[Spice-devel] [PATCH 5/7] RedChannel: Add FOREACH_CLIENT and use it to iterate

2016-05-20 Thread Jonathon Jongsma
Remove the custom FOREACH_DCC macro and use the more generic FOREACH_CLIENT macro and use it for all channels. --- server/display-channel.c | 20 ++-- server/display-channel.h | 9 - server/main-channel.c| 32 +++- server/red-channel.c |

[Spice-devel] [PATCH 2/7] change main_channel_marshall_mouse_mode call style

2016-05-20 Thread Jonathon Jongsma
From: Frediano Ziglio Make the call more similar to other marshall function calls in the same function. Signed-off-by: Frediano Ziglio --- server/main-channel-client.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/server/main-channel-client.c b/server/main-channe

[Spice-devel] [PATCH 0/7] Rebased patches from refactory

2016-05-20 Thread Jonathon Jongsma
Just a small set of patches incorporating some comments from previous review. The new "Add FOREACH_CLIENT" commit was in response to Frediano's request to use a macro for looping through clients in his review of "Replace RedChannel::clients with GList". This new commit could be squashed into that o

[Spice-devel] [PATCH 1/7] move all item creation in main-channel-client.c

2016-05-20 Thread Jonathon Jongsma
From: Frediano Ziglio Move all core to create and destroy MainChannel pipe items in a single place. Signed-off-by: Frediano Ziglio --- server/main-channel-client.c | 34 ++ server/main-channel-client.h | 15 +-- server/main-channel.c| 29 +---

[Spice-devel] [PATCH 6/7] Replace RedClient::channels with GList

2016-05-20 Thread Jonathon Jongsma
Allows us to not expose the client_link in RedChannelClient. Acked-by: Pavel Grunt --- server/red-channel.c | 51 --- server/red-channel.h | 5 + 2 files changed, 29 insertions(+), 27 deletions(-) diff --git a/server/red-channel.c b/server/re

[Spice-devel] [PATCH 4/7] Replace RedChannel::clients with GList

2016-05-20 Thread Jonathon Jongsma
Instead of using a Ring, use a GList to store the list of channel clients. This allows us to iterate the clients without poking inside of the client struct to get the channel_link. This is required in order to make the RedChannelClient struct private. --- server/display-channel.c | 64 ---

Re: [Spice-devel] [PATCH 11/11] Get code more typesafe

2016-05-20 Thread Jonathon Jongsma
Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > Scan remaining code searching for problems with structure > layout assumptions in the code. > Where code required some restructuring put some verify checks > to make sure code won't compile if these assumptions

Re: [Spice-devel] [PATCH 10/11] Make sure link in RedPipeItem can be not the first field

2016-05-20 Thread Jonathon Jongsma
In general, this is a good idea, but I question why you're doing it now. There are patches already in the refactory branch which change the PipeItem ring into a GList (although perhaps GQueue might be more appropriate). That patch would also fix the underlying issue you're solving here. So having b

Re: [Spice-devel] [PATCH 09/11] reduce casts to RedPipeItem and RingItem

2016-05-20 Thread Jonathon Jongsma
Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > Make code more type safe. This allow to move or delete structure > fields more safely > > Signed-off-by: Frediano Ziglio > --- > server/dcc.c | 6 +++--- > server/reds.c | 2 +- > server/smartcard

Re: [Spice-devel] [PATCH 08/11] rename RedVDIReadBug::parent to base

2016-05-20 Thread Jonathon Jongsma
Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > All other classes using RedPipeItem as base use base as parent name > > Signed-off-by: Frediano Ziglio > --- > server/reds.c | 22 +++--- > 1 file changed, 11 insertions(+), 11 deletions(-) >

Re: [Spice-devel] [PATCH 07/11] make red_pipe_item_unref more typesafe

2016-05-20 Thread Jonathon Jongsma
ok, I'll take some added typesafety over a having to pass the ->parent occasionally Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > Signed-off-by: Frediano Ziglio > --- > server/char-device.c | 2 +- > server/red-pipe-item.c | 4 +--- > server/red-pi

Re: [Spice-devel] [PATCH 06/11] make red_pipe_item_ref more typesafe

2016-05-20 Thread Jonathon Jongsma
Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > Signed-off-by: Frediano Ziglio > --- > server/red-pipe-item.c | 4 +--- > server/red-pipe-item.h | 2 +- > server/reds.c | 2 +- > server/spicevmc.c | 4 ++-- > 4 files changed, 5 insertions(+),

Re: [Spice-devel] [PATCH 05/11] make red_pipe_item_init_full more typesafe

2016-05-20 Thread Jonathon Jongsma
Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > Use a proper type for free callback > > Signed-off-by: Frediano Ziglio > --- > server/cursor-channel.c | 10 ++ > server/dcc.c| 8 +--- > server/main-channel.c | 10 ++ > s

Re: [Spice-devel] [PATCH 04/11] Use a marker instead of checking a RedPipeItem presence

2016-05-20 Thread Jonathon Jongsma
I would prefer a more elegant long-term solution, but this is OK as a short-term solution Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > This avoids having to retain a pointer just to check item is still in > the queue with ring_item_is_linked(&item->link

Re: [Spice-devel] [PATCH 03/11] Call dcc_send_item directly

2016-05-20 Thread Jonathon Jongsma
Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > Signed-off-by: Frediano Ziglio > --- > server/dcc-send.c| 4 ++-- > server/dcc.h | 2 +- > server/display-channel.c | 7 +-- > 3 files changed, 4 insertions(+), 9 deletions(-) > > di

Re: [Spice-devel] [PATCH 02/11] Handle reference for RedPipeItem in RedChannel

2016-05-20 Thread Jonathon Jongsma
Better. Acked-by: Jonathon Jongsma On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > Remove the need to release the item inside send_item callbacks. > This looks like a partial rollback of previous patch but is > to make clear the intention of the change. > The lifetime of items could

Re: [Spice-devel] [PATCH 01/11] Remove RedChannel::hold_item callback

2016-05-20 Thread Jonathon Jongsma
On Fri, 2016-05-20 at 14:01 +0100, Frediano Ziglio wrote: > This is quite confusing and prone to errors. > Use RedPipeItem reference counting instead. > To compensate for the additional reference due to red_pipe_item_ref > in RedChannel sub class with empty hold_item have to add a > red_pipe_item_u

Re: [Spice-devel] [PATCH spice-gtk 1/7] util: remove STATIC_MUTEX macros

2016-05-20 Thread Frediano Ziglio
> > They are no longer needed since 0a9ec4ec0. > > Signed-off-by: Marc-André Lureau > --- > src/channel-usbredir.c | 10 +- > src/spice-channel-priv.h | 2 +- > src/spice-channel.c | 28 ++-- > src/spice-util-priv.h| 6 -- > 4 files changed, 20 i

Re: [Spice-devel] [PATCH spice-gtk 5/7] egl: fix multiple gl display flickering

2016-05-20 Thread Marc-André Lureau
On Fri, May 20, 2016 at 5:16 PM, Marc-André Lureau wrote: > For some unclear reason, when multiple display use gl in the same > process (with virt-manager for ex), the texture content can be > overwritten by another display on update. > > Although the gl contexts are differents when using multiple

[Spice-devel] [PATCH spice-gtk 5/7] egl: fix multiple gl display flickering

2016-05-20 Thread Marc-André Lureau
For some unclear reason, when multiple display use gl in the same process (with virt-manager for ex), the texture content can be overwritten by another display on update. Although the gl contexts are differents when using multiple widgets, even when sharing a texture ID, it shouldn't overwrite the

[Spice-devel] [PATCH spice-gtk 3/7] egl: don't destroy wayland egl context

2016-05-20 Thread Marc-André Lureau
The egl context is from Gtk on Wayland. Destroy it only on X11. Signed-off-by: Marc-André Lureau --- src/spice-widget-egl.c | 25 ++--- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/src/spice-widget-egl.c b/src/spice-widget-egl.c index 7611b0b..fff2831 10064

[Spice-devel] [PATCH spice-gtk 7/7] egl: set current context, fix multiple display

2016-05-20 Thread Marc-André Lureau
On X11, each widget has its own context. Make sure we are using the widget associated context when using gl. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1337721 Signed-off-by: Marc-André Lureau --- src/spice-widget-egl.c | 15 +++ 1 file changed, 15 insertions(+) diff --git

[Spice-devel] [PATCH spice-gtk 6/7] egl: don't terminate display

2016-05-20 Thread Marc-André Lureau
This is global to the display connection: all egl resources will be released, including those from other widgets or from the application. Fix spice/virgl display being rendered black after another widget display is destroyed. Signed-off-by: Marc-André Lureau --- src/spice-widget-egl.c | 1 - 1

[Spice-devel] [PATCH spice-gtk 4/7] egl: only swap buffers on x11

2016-05-20 Thread Marc-André Lureau
Gtk does it for us already with GtkGlArea. Signed-off-by: Marc-André Lureau --- src/spice-widget-egl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/spice-widget-egl.c b/src/spice-widget-egl.c index fff2831..210b834 100644 --- a/src/spice-widget-egl.c +++ b/src/spice

[Spice-devel] [PATCH spice-gtk 2/7] channel: check if channel has a session

2016-05-20 Thread Marc-André Lureau
Since 8943d2329, the channel may be disconnected from the session before it's destroyed. In this case, session is NULL. Fixes some critical with virt-manager when closing a display: (virt-manager:20451): GSpice-CRITICAL **: spice_session_is_for_migration: assertion 'SPICE_IS_SESSION(session)' fa

[Spice-devel] [PATCH spice-gtk 1/7] util: remove STATIC_MUTEX macros

2016-05-20 Thread Marc-André Lureau
They are no longer needed since 0a9ec4ec0. Signed-off-by: Marc-André Lureau --- src/channel-usbredir.c | 10 +- src/spice-channel-priv.h | 2 +- src/spice-channel.c | 28 ++-- src/spice-util-priv.h| 6 -- 4 files changed, 20 insertions(+), 26 dele

[Spice-devel] [spice-gtk] RFC Sync only on focus change

2016-05-20 Thread Frediano Ziglio
Limit the virtual keystrokes sent to the remote machine. The modifiers are synced only when the application receive or lose the focus. This reduce a lot the possible virtual keystrokes sent to the guest to synchronize the modifiers. This affect the situations where modifiers are configured differen

Re: [Spice-devel] RedPipeItem lifespan, past, present and ... bug

2016-05-20 Thread Frediano Ziglio
> > On Thu, 2016-05-19 at 18:25 +0200, Christophe Fergeau wrote: > > Hey, > > > > On Thu, May 19, 2016 at 06:14:52AM -0400, Frediano Ziglio wrote: > > > Possible future changes (please comment): > > > - would be good if red_channel_client_wait_pipe_item_sent could work even > > > without the ho

[Spice-devel] [PATCH 05/11] make red_pipe_item_init_full more typesafe

2016-05-20 Thread Frediano Ziglio
Use a proper type for free callback Signed-off-by: Frediano Ziglio --- server/cursor-channel.c | 10 ++ server/dcc.c| 8 +--- server/main-channel.c | 10 ++ server/red-channel.c| 6 -- server/red-pipe-item.c | 4 ++-- server/red-pipe-item.h | 10 +++

[Spice-devel] [PATCH 07/11] make red_pipe_item_unref more typesafe

2016-05-20 Thread Frediano Ziglio
Signed-off-by: Frediano Ziglio --- server/char-device.c | 2 +- server/red-pipe-item.c | 4 +--- server/red-pipe-item.h | 2 +- server/reds.c | 12 +--- 4 files changed, 8 insertions(+), 12 deletions(-) diff --git a/server/char-device.c b/server/char-device.c index b67e192.

[Spice-devel] [PATCH 10/11] Make sure link in RedPipeItem can be not the first field

2016-05-20 Thread Frediano Ziglio
There are many line of code were this assumption is in place. For instance RedPipeItem* is converted to RingItem* or viceversa. Use SPICE_CONTAINEROF to make sure link is in RedPipeItem and the offset is computed correctly. Also check that RingItem pointer is checked before SPICE_CONTAINEROF. On th

[Spice-devel] [PATCH 04/11] Use a marker instead of checking a RedPipeItem presence

2016-05-20 Thread Frediano Ziglio
This avoids having to retain a pointer just to check item is still in the queue with ring_item_is_linked(&item->link). Signed-off-by: Frediano Ziglio --- server/red-channel.c | 30 ++ server/red-channel.h | 1 + 2 files changed, 27 insertions(+), 4 deletions(-) diff

[Spice-devel] [PATCH 00/11] RedChannel refcounting and type safety

2016-05-20 Thread Frediano Ziglio
This patchset collect 2 different changes: - work on RedChannel for reference counting changes and cleanup; - different type safety improvements to avoid structure layout assumption and make easier to move/remove fields on different structures. Frediano Ziglio (11): Remove RedChannel::hold

[Spice-devel] [PATCH 01/11] Remove RedChannel::hold_item callback

2016-05-20 Thread Frediano Ziglio
This is quite confusing and prone to errors. Use RedPipeItem reference counting instead. To compensate for the additional reference due to red_pipe_item_ref in RedChannel sub class with empty hold_item have to add a red_pipe_item_unref call in send_item. Signed-off-by: Frediano Ziglio --- server

[Spice-devel] [PATCH 06/11] make red_pipe_item_ref more typesafe

2016-05-20 Thread Frediano Ziglio
Signed-off-by: Frediano Ziglio --- server/red-pipe-item.c | 4 +--- server/red-pipe-item.h | 2 +- server/reds.c | 2 +- server/spicevmc.c | 4 ++-- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/server/red-pipe-item.c b/server/red-pipe-item.c index cc0ab5a..74bf267

[Spice-devel] [PATCH 09/11] reduce casts to RedPipeItem and RingItem

2016-05-20 Thread Frediano Ziglio
Make code more type safe. This allow to move or delete structure fields more safely Signed-off-by: Frediano Ziglio --- server/dcc.c | 6 +++--- server/reds.c | 2 +- server/smartcard.c | 4 ++-- server/spicevmc.c | 5 ++--- server/stream.c| 2 +- 5 files changed, 9 insertions(+),

[Spice-devel] [PATCH 11/11] Get code more typesafe

2016-05-20 Thread Frediano Ziglio
Scan remaining code searching for problems with structure layout assumptions in the code. Where code required some restructuring put some verify checks to make sure code won't compile if these assumptions are not in place anymore. Signed-off-by: Frediano Ziglio --- server/cache-item.tmpl.c | 1

[Spice-devel] [PATCH 08/11] rename RedVDIReadBug::parent to base

2016-05-20 Thread Frediano Ziglio
All other classes using RedPipeItem as base use base as parent name Signed-off-by: Frediano Ziglio --- server/reds.c | 22 +++--- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/server/reds.c b/server/reds.c index 74de7d5..fa9a79e 100644 --- a/server/reds.c +++ b/

[Spice-devel] [PATCH 03/11] Call dcc_send_item directly

2016-05-20 Thread Frediano Ziglio
Signed-off-by: Frediano Ziglio --- server/dcc-send.c| 4 ++-- server/dcc.h | 2 +- server/display-channel.c | 7 +-- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/server/dcc-send.c b/server/dcc-send.c index 05da07f..8ec22c8 100644 --- a/server/dcc-send.c +

[Spice-devel] [PATCH 02/11] Handle reference for RedPipeItem in RedChannel

2016-05-20 Thread Frediano Ziglio
Remove the need to release the item inside send_item callbacks. This looks like a partial rollback of previous patch but is to make clear the intention of the change. The lifetime of items could extend a bit further but there are no cases this small lag should cause problems. Signed-off-by: Fredia

Re: [Spice-devel] [PATCH spice-gtk v3 6/7] spice-uri: Check if port is in allowed range

2016-05-20 Thread Pavel Grunt
On Fri, 2016-05-20 at 14:50 +0200, Christophe Fergeau wrote: > On Thu, May 19, 2016 at 06:38:08PM +0200, Pavel Grunt wrote: > > Related: rhbz#1335239 > > --- > >  src/spice-uri.c| 8 ++-- > >  tests/test-spice-uri.c | 2 ++ > >  2 files changed, 8 insertions(+), 2 deletions(-) > > > > di

[Spice-devel] [PATCH spice-gtk 1/5] test-session: Fix signed compare

2016-05-20 Thread Pavel Grunt
The varible is compared with G_N_ELEMENTS which returns unsigned value --- tests/session.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/session.c b/tests/session.c index d065b60..00076f2 100644 --- a/tests/session.c +++ b/tests/session.c @@ -3,7 +3,7 @@ static void te

[Spice-devel] [PATCH spice-gtk 5/5] test-session: Test invalid URIs

2016-05-20 Thread Pavel Grunt
--- tests/session.c | 30 -- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/tests/session.c b/tests/session.c index 00a5a1e..eace40a 100644 --- a/tests/session.c +++ b/tests/session.c @@ -1,6 +1,31 @@ #include -static void test_session_uri(void) +sta

[Spice-devel] [PATCH spice-gtk 0/5] Add more tests for the session's uri

2016-05-20 Thread Pavel Grunt
Hi, I plan to merge both uri parsers (one is in spice-session, one in spice-uri). These patches add more to tests to avoid regressions. Thanks, Pavel Grunt (5): test-session: Fix signed compare test-session: Test alternative way for setting port test-session: Do not fail on g_warning tes

[Spice-devel] [PATCH spice-gtk 3/5] test-session: Do not fail on g_warning

2016-05-20 Thread Pavel Grunt
Following commit adds tests for password set in uri which will produce a runtime warning. Reset fatal mask set by g_test_init() to avoid failing. --- tests/session.c | 9 + 1 file changed, 9 insertions(+) diff --git a/tests/session.c b/tests/session.c index a6276c2..549378b 100644 --- a/t

[Spice-devel] [PATCH spice-gtk 2/5] test-session: Test alternative way for setting port

2016-05-20 Thread Pavel Grunt
--- tests/session.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/tests/session.c b/tests/session.c index 00076f2..a6276c2 100644 --- a/tests/session.c +++ b/tests/session.c @@ -24,6 +24,12 @@ static void test_session_uri(void) { NULL, "5930", "spice://localhost?por

[Spice-devel] [PATCH spice-gtk 4/5] test-session: Also test hostname, username and password

2016-05-20 Thread Pavel Grunt
--- tests/session.c | 48 +--- 1 file changed, 45 insertions(+), 3 deletions(-) diff --git a/tests/session.c b/tests/session.c index 549378b..00a5a1e 100644 --- a/tests/session.c +++ b/tests/session.c @@ -8,33 +8,63 @@ static void test_session_uri(void)

Re: [Spice-devel] [PATCH spice-gtk v3 6/7] spice-uri: Check if port is in allowed range

2016-05-20 Thread Christophe Fergeau
On Thu, May 19, 2016 at 06:38:08PM +0200, Pavel Grunt wrote: > Related: rhbz#1335239 > --- > src/spice-uri.c| 8 ++-- > tests/test-spice-uri.c | 2 ++ > 2 files changed, 8 insertions(+), 2 deletions(-) > > diff --git a/src/spice-uri.c b/src/spice-uri.c > index b483374..6a43461 100644

Re: [Spice-devel] [PATCH spice-gtk v3 4/7] spice-uri: Reset SpiceUri before parsing

2016-05-20 Thread Christophe Fergeau
On Fri, May 20, 2016 at 11:07:58AM +0200, Pavel Grunt wrote: > > > diff --git a/src/spice-uri.c b/src/spice-uri.c > > > index 3bdb502..04ea3cb 100644 > > > --- a/src/spice-uri.c > > > +++ b/src/spice-uri.c > > > @@ -105,6 +105,13 @@ gboolean spice_uri_parse(SpiceURI *self, const gchar > > > *_uri,

Re: [Spice-devel] Cross-platform mobile (iOS and Android) client

2016-05-20 Thread Sergio L. Pascual
On Thu, 2016-05-19 at 11:10 +0200, Christophe Fergeau wrote: > Is this in anyway related to > https://github.com/iiordanov/remote-desktop-clients ? Or did you > start > the Android client from scratch? There could be some similarities in our glue code, as we took a look at it to quickly find the e

Re: [Spice-devel] [spice-gtk v1 6/9] file-xfer: a FileTransferOperation per transfer call

2016-05-20 Thread Victor Toso
On Thu, May 19, 2016 at 01:21:46PM +0200, Victor Toso wrote: > Each call to spice_main_file_copy_async will now create a > FileTransferOperation which groups all SpiceFileTransferTasks of the > copy operation and also the progress_callback passed from Application. > > As pointed in the fix 113093d

Re: [Spice-devel] Gtk-doc VS Doxygen

2016-05-20 Thread Daniel P. Berrange
On Fri, May 20, 2016 at 06:44:01AM -0400, Frediano Ziglio wrote: > Hi, > I'd like to have some standard on the internal documentation of > spice-server. > > The current situation is quite messy having different styles. > I think the worst think is not having any documentation, so better messy >

[Spice-devel] Gtk-doc VS Doxygen

2016-05-20 Thread Frediano Ziglio
Hi, I'd like to have some standard on the internal documentation of spice-server. The current situation is quite messy having different styles. I think the worst think is not having any documentation, so better messy than nothing. I really like Doxygen as it's really complete tool however my Gtk

[Spice-devel] [PATCH] Use a marker instead of checking a RedPipeItem presence

2016-05-20 Thread Frediano Ziglio
This avoids having to retain a pointer just to check item is still in the queue with ring_item_is_linked(&item->link). Signed-off-by: Frediano Ziglio --- server/red-channel.c | 30 ++ server/red-channel.h | 1 + 2 files changed, 27 insertions(+), 4 deletions(-) diff

Re: [Spice-devel] [PATCH v2] remove a warning building a test

2016-05-20 Thread Frediano Ziglio
> > On 05/18/2016 07:14 AM, Christophe Fergeau wrote: > > On Wed, May 18, 2016 at 12:46:03PM +0300, Uri Lublin wrote: > >> > >> In man cmsg examples I see they use a pointer: > >> int *pi = (int*) CMSG_DATA(cmsg); > >> *fd = *pi; > > > > It seems to work this way, but I'm not sure why this works

[Spice-devel] [PATCH 3/3] Call dcc_send_item directly

2016-05-20 Thread Frediano Ziglio
Signed-off-by: Frediano Ziglio --- server/dcc-send.c| 4 ++-- server/dcc.h | 2 +- server/display-channel.c | 7 +-- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/server/dcc-send.c b/server/dcc-send.c index 05da07f..8ec22c8 100644 --- a/server/dcc-send.c +

[Spice-devel] [PATCH 2/3] Handle reference for RedPipeItem in RedChannel

2016-05-20 Thread Frediano Ziglio
Remove the need to release the item inside send_item callbacks. This looks like a partial rollback of previous patch but is to make clear the intention of the change. The lifetime of items could extend a bit further but there are no cases this small lag should cause problems. Signed-off-by: Fredia

[Spice-devel] [PATCH 1/3] Remove RedChannel::hold_item callback

2016-05-20 Thread Frediano Ziglio
This is quite confusing and prone to errors. Use RedPipeItem reference counting instead. To compensate for the additional reference due to red_pipe_item_ref in RedChannel sub class with empty hold_item have to add a red_pipe_item_unref call in send_item. Signed-off-by: Frediano Ziglio --- server

Re: [Spice-devel] [PATCH spice-gtk v3 6/7] spice-uri: Check if port is in allowed range

2016-05-20 Thread Pavel Grunt
On Fri, 2016-05-20 at 10:36 +0200, Victor Toso wrote: > Hi, > > On Thu, May 19, 2016 at 06:38:08PM +0200, Pavel Grunt wrote: > > Related: rhbz#1335239 > > --- > >  src/spice-uri.c| 8 ++-- > >  tests/test-spice-uri.c | 2 ++ > >  2 files changed, 8 insertions(+), 2 deletions(-) > > > >

Re: [Spice-devel] [PATCH spice-gtk v3 3/7] spice-uri: Add missing include

2016-05-20 Thread Pavel Grunt
On Fri, 2016-05-20 at 10:14 +0200, Victor Toso wrote: > Hi, > > On Thu, May 19, 2016 at 06:38:05PM +0200, Pavel Grunt wrote: > > Related: rhbz#1335239 > > --- > >  src/spice-uri.c | 1 + > >  1 file changed, 1 insertion(+) > > > > diff --git a/src/spice-uri.c b/src/spice-uri.c > > index 8cf870d..3

Re: [Spice-devel] [PATCH spice-gtk v3 5/7] spice-uri: Do not allow empty port string

2016-05-20 Thread Pavel Grunt
On Fri, 2016-05-20 at 10:32 +0200, Victor Toso wrote: > Hi, > > On Thu, May 19, 2016 at 06:38:07PM +0200, Pavel Grunt wrote: > > Related: rhbz#1335239 > > --- > >  src/spice-uri.c| 3 +++ > >  tests/test-spice-uri.c | 1 + > >  2 files changed, 4 insertions(+) > > > > diff --git a/src/spice

Re: [Spice-devel] [PATCH spice-gtk v3 4/7] spice-uri: Reset SpiceUri before parsing

2016-05-20 Thread Pavel Grunt
On Fri, 2016-05-20 at 10:24 +0200, Victor Toso wrote: > Hi, > > On Thu, May 19, 2016 at 06:38:06PM +0200, Pavel Grunt wrote: > > Avoid using old values after parsing a new uri. > > A test case with re-using the SpiceURI could be handy > All the tests are reusing SpiceURI > > > > Related: rhbz#

Re: [Spice-devel] [PATCH spice-gtk v3 7/7] spice-uri: Add ipv6 support

2016-05-20 Thread Pavel Grunt
On Fri, 2016-05-20 at 10:54 +0200, Victor Toso wrote: > Hi, > > On Thu, May 19, 2016 at 06:38:09PM +0200, Pavel Grunt wrote: > > Just basic support -  http://user:password@[host]:port > > > > Resolves: rhbz#1335239 > > --- > >  src/spice-uri.c| 25 + > >  tests/test

Re: [Spice-devel] [PATCH spice-gtk v3 7/7] spice-uri: Add ipv6 support

2016-05-20 Thread Victor Toso
Hi, On Thu, May 19, 2016 at 06:38:09PM +0200, Pavel Grunt wrote: > Just basic support - http://user:password@[host]:port > > Resolves: rhbz#1335239 > --- > src/spice-uri.c| 25 + > tests/test-spice-uri.c | 42 ++ > 2 files

Re: [Spice-devel] [PATCH spice-gtk v3 6/7] spice-uri: Check if port is in allowed range

2016-05-20 Thread Victor Toso
Hi, On Thu, May 19, 2016 at 06:38:08PM +0200, Pavel Grunt wrote: > Related: rhbz#1335239 > --- > src/spice-uri.c| 8 ++-- > tests/test-spice-uri.c | 2 ++ > 2 files changed, 8 insertions(+), 2 deletions(-) > > diff --git a/src/spice-uri.c b/src/spice-uri.c > index b483374..6a43461 10

Re: [Spice-devel] [PATCH spice-gtk v3 5/7] spice-uri: Do not allow empty port string

2016-05-20 Thread Victor Toso
On Fri, May 20, 2016 at 10:32:00AM +0200, Victor Toso wrote: > Hi, > > On Thu, May 19, 2016 at 06:38:07PM +0200, Pavel Grunt wrote: > > Related: rhbz#1335239 > > --- > > src/spice-uri.c| 3 +++ > > tests/test-spice-uri.c | 1 + > > 2 files changed, 4 insertions(+) > > > > diff --git a/sr

Re: [Spice-devel] [PATCH spice-gtk v3 5/7] spice-uri: Do not allow empty port string

2016-05-20 Thread Victor Toso
Hi, On Thu, May 19, 2016 at 06:38:07PM +0200, Pavel Grunt wrote: > Related: rhbz#1335239 > --- > src/spice-uri.c| 3 +++ > tests/test-spice-uri.c | 1 + > 2 files changed, 4 insertions(+) > > diff --git a/src/spice-uri.c b/src/spice-uri.c > index 04ea3cb..b483374 100644 > --- a/src/spice

Re: [Spice-devel] [PATCH spice-gtk v3 4/7] spice-uri: Reset SpiceUri before parsing

2016-05-20 Thread Victor Toso
Hi, On Thu, May 19, 2016 at 06:38:06PM +0200, Pavel Grunt wrote: > Avoid using old values after parsing a new uri. A test case with re-using the SpiceURI could be handy > > Related: rhbz#1335239 > --- > src/spice-uri.c| 7 +++ > tests/test-spice-uri.c | 4 ++-- > 2 files changed, 9

Re: [Spice-devel] [PATCH spice-gtk v3 3/7] spice-uri: Add missing include

2016-05-20 Thread Victor Toso
Hi, On Thu, May 19, 2016 at 06:38:05PM +0200, Pavel Grunt wrote: > Related: rhbz#1335239 > --- > src/spice-uri.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/src/spice-uri.c b/src/spice-uri.c > index 8cf870d..3bdb502 100644 > --- a/src/spice-uri.c > +++ b/src/spice-uri.c > @@ -22,6 +

Re: [Spice-devel] [PATCH spice-gtk v3 2/7] spice-uri: Mark parameter as unused

2016-05-20 Thread Victor Toso
On Thu, May 19, 2016 at 06:38:04PM +0200, Pavel Grunt wrote: > --- > src/spice-uri.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/spice-uri.c b/src/spice-uri.c > index e1317bd..8cf870d 100644 > --- a/src/spice-uri.c > +++ b/src/spice-uri.c > @@ -340,7 +340,7 @@ sta

Re: [Spice-devel] [PATCH spice-gtk v3 1/7] tests: Add test for SpiceUri

2016-05-20 Thread Victor Toso
Hi, On Thu, May 19, 2016 at 06:38:03PM +0200, Pavel Grunt wrote: > Related: rhbz#1335239 > --- > tests/Makefile.am | 2 ++ > tests/test-spice-uri.c | 73 > ++ > 2 files changed, 75 insertions(+) > create mode 100644 tests/test-spice-uri.c >