[Spice-devel] [PATCH] spice-widget: fixing issue with keyboard already grabbed

2018-05-21 Thread Julio Faracco
For some reason, after unlocking a locked screen, spice receives an enter event before focus-in event (this possible a Gtk issue). This wrong sequence of events is causing a wrong mouse focus. This operation gives to enter event the ability to grab keyboard and when focus-in event is raised, keyboa

Re: [Spice-devel] [PATCH spice-gtk] spice-widget: fixing issue with keyboard already grabbed

2018-05-21 Thread Victor Toso
Hi, Thanks for trying to fix this issue. On Mon, May 21, 2018 at 12:50:38AM -0300, Julio Faracco wrote: > For some reason, after unlocking a locked screen, spice receives an > enter event before focus-in event (this possible a Gtk issue). Yes.. > This wrong sequence of events is causing a wrong

Re: [Spice-devel] [PATCH] usbredirhost: host should not be marked as claimed on failure

2018-05-21 Thread Qiu Wenbo
You are right. I have changed my patch. diff --git a/usbredirhost/usbredirhost.c b/usbredirhost/usbredirhost.c index 3666227..609cf09 100644 --- a/usbredirhost/usbredirhost.c +++ b/usbredirhost/usbredirhost.c @@ -557,12 +557,20 @@ static int usbredirhost_claim(struct usbredirhost *host, int init

[Spice-devel] [PATCH spice-streaming-agent v2 5/5] Provide helper to give information to daemon

2018-05-21 Thread Frediano Ziglio
This is required so the daemon can manage the various sessions. The helper is launched every time a graphic session is started. It sends information to the daemon on how to connect to the given display server. Signed-off-by: Frediano Ziglio --- data/spice-streaming.desktop.in | 3 +-- spice-str

[Spice-devel] [PATCH spice-streaming-agent v2 1/4] Add some information to the log

2018-05-21 Thread Frediano Ziglio
Allows to track different frame timing. Signed-off-by: Frediano Ziglio --- src/spice-streaming-agent.cpp | 15 +++ 1 file changed, 15 insertions(+) diff --git a/src/spice-streaming-agent.cpp b/src/spice-streaming-agent.cpp index 434489f..b30e968 100644 --- a/src/spice-streaming-agen

[Spice-devel] [PATCH spice-streaming-agent v2 2/4] Enable line buffering instead of full buffering for the log

2018-05-21 Thread Frediano Ziglio
Allows to kill the process without losing log lines Signed-off-by: Frediano Ziglio --- src/spice-streaming-agent.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/spice-streaming-agent.cpp b/src/spice-streaming-agent.cpp index b30e968..9ccc9da 100644 --- a/src/spice-streaming-agent.cpp

[Spice-devel] [PATCH spice-streaming-agent v2] Detect and handle exception creating capture engine

2018-05-21 Thread Frediano Ziglio
Currently exception from a plugin are not handled when creating a capture engine. Capture the exception and try to use another plugin instead of bailing out. This was tested with an experimental GStreamer plugin. Signed-off-by: Frediano Ziglio --- src/concrete-agent.cpp | 9 - 1 file cha

[Spice-devel] [PATCH spice-streaming-agent v2 4/4] Add option to set logging categories

2018-05-21 Thread Frediano Ziglio
Allows to enable/disable different categories of logging. Currently disabling by default logging of full frame data which can take huge amount of log and allow to enable it if needed. Signed-off-by: Frediano Ziglio --- src/spice-streaming-agent.cpp | 15 ++- 1 file changed, 14 insert

[Spice-devel] [PATCH spice-streaming-agent v2 2/5] Add file with utilities for Xorg

2018-05-21 Thread Frediano Ziglio
Signed-off-by: Frediano Ziglio --- src/Makefile.am | 2 ++ src/spice-streaming-agent.cpp | 1 + src/xorg-utils.cpp| 40 +++ src/xorg-utils.hpp| 13 4 files changed, 56 insertions(+) create mode 100644 src/xorg-u

[Spice-devel] [PATCH spice-streaming-agent v2 4/5] Implement a daemon/agent separation

2018-05-21 Thread Frediano Ziglio
This allows to manage properly multiple servers (currently only Xorg). The executable will run as a service forking the proper agent. The agent will then manage the active server. The server receive just minimal information for the various graphic terminals and use to fork the agent. Signed-off-by

[Spice-devel] [PATCH spice-streaming-agent v2 3/5] Starts/stops the agent based on VT status

2018-05-21 Thread Frediano Ziglio
Check if the current display server is active or not and stream only if active. This will allow to support multiple display servers running. When multiple display servers are running only one have the GPU associated and is writing to the screen. Stop capturing and release resources when the display

[Spice-devel] [PATCH spice-streaming-agent v2 3/4] Always log statistics

2018-05-21 Thread Frediano Ziglio
Allow to see frame size even if frame data is disabled. Useful to compute frame statistics not spending huge amount of space for frame data. Signed-off-by: Frediano Ziglio --- src/spice-streaming-agent.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/spice-streami

[Spice-devel] [PATCH spice-streaming-agent v2 1/5] Install udev rule

2018-05-21 Thread Frediano Ziglio
The udev rule is used to do some action when the device is added to the system. Current rule change the permission of the special file to allow to open it by any user. Some systems use /lib/udev while others use /usr/lib/udev. Allow to specify the full path to support both type of systems. Signed-

[Spice-devel] [spice-gtk] widget: update comment on fixed gtk+ bug

2018-05-21 Thread Victor Toso
From: Victor Toso The bug was fixed in GTK+ 3.22. I'm updating the comment plus setting the !GTK_CHECK_VERSION() to track changes that can be removed after bumping the gtk+ library. Signed-off-by: Victor Toso --- src/spice-widget.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) d

Re: [Spice-devel] [PATCH spice-common] marshaller: Remove initial underscore from static function

2018-05-21 Thread Eduardo Lima (Etrunko)
On 18/05/18 16:09, Frediano Ziglio wrote: > This is the only function starting with an underscore, looks > out of style. > > Signed-off-by: Frediano Ziglio Acked-by: Eduardo Lima (Etrunko) > --- > common/marshaller.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git

Re: [Spice-devel] [PATCH spice-streaming-agent v2 3/4] Always log statistics

2018-05-21 Thread Uri Lublin
On 05/21/2018 01:23 PM, Frediano Ziglio wrote: Allow to see frame size even if frame data is disabled. Useful to compute frame statistics not spending huge amount of space for frame data. Signed-off-by: Frediano Ziglio --- src/spice-streaming-agent.cpp | 5 ++--- 1 file changed, 2 insertions

Re: [Spice-devel] [PATCH spice-streaming-agent v2 3/4] Always log statistics

2018-05-21 Thread Frediano Ziglio
> > On 05/21/2018 01:23 PM, Frediano Ziglio wrote: > > Allow to see frame size even if frame data is disabled. > > Useful to compute frame statistics not spending huge amount of space > > for frame data. > > > > Signed-off-by: Frediano Ziglio > > --- > > src/spice-streaming-agent.cpp | 5 ++---

Re: [Spice-devel] [PATCH spice-streaming-agent v2 2/4] Enable line buffering instead of full buffering for the log

2018-05-21 Thread Uri Lublin
On 05/21/2018 01:23 PM, Frediano Ziglio wrote: Allows to kill the process without losing log lines Hi Frediano, 1. What happens when binary frames are logged ? 2. When the process is killed (with e.g. SIGTERM), supposedly the event is caught and the file is (flushed and) closed. Uri. S

Re: [Spice-devel] [PATCH spice-streaming-agent v2 2/4] Enable line buffering instead of full buffering for the log

2018-05-21 Thread Frediano Ziglio
> > On 05/21/2018 01:23 PM, Frediano Ziglio wrote: > > Allows to kill the process without losing log lines > > Hi Frediano, > > 1. What happens when binary frames are logged ? > man setlinebuf for details, but maybe more consistent to exclude this if log_binary is true. > 2. When the process

[Spice-devel] [spice-gtk] widget: avoid gdk_seat_grab/ungrab() API temporarily

2018-05-21 Thread Victor Toso
From: Victor Toso We are using those APIs to avoid the deprecated ones from GTK but unexpected events are handled different by them introducing a regression that is easy to reproduce when Spice client holds the focus and user locks the screen. We need to better handle the situation where gdk_sea