Hello community,

here is the log from the commit of package xpra for openSUSE:Factory checked in 
at 2020-02-10 21:54:34
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/xpra (Old)
 and      /work/SRC/openSUSE:Factory/.xpra.new.26092 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "xpra"

Mon Feb 10 21:54:34 2020 rev:15 rq:772661 version:3.0.6

Changes:
--------
--- /work/SRC/openSUSE:Factory/xpra/xpra.changes        2020-02-04 
19:54:13.129351890 +0100
+++ /work/SRC/openSUSE:Factory/.xpra.new.26092/xpra.changes     2020-02-10 
21:54:43.898234379 +0100
@@ -1,0 +2,46 @@
+Mon Feb 10 11:20:15 UTC 2020 - Luigi Baldoni <aloi...@gmx.com>
+
+- Update to version 3.0.6
+  * fix UDP with Python3
+  * fix key mapping issues with non-X11 clients and non-US
+    layouts
+  * fix notification logging errors during shutdown
+  * fix window stacking order with html5 client and override
+    redirect windows
+  * fix png/P and png/L decoding
+  * fix very slow startup on Debian due to missing
+    libfakeXinerama
+  * fix display scaling notification warning
+  * fix errors generating the tray title string
+  * fix missing webp modules in 'clean' build target
+  * fix some special characters with HTML5 client
+  * fix initiate-moveresize with multiple clients
+  * fix control commands argument error handling
+  * fix unit tests
+  * fix window repaint issues: system tray, Python 2 non-opengl
+    window spinners
+  * fix server errors during client connection cleanup
+  * fix spacebar and other characters with tablet input devices
+    (ie: mobile browsers)
+  * fix unhelpful backtraces when client application windows are
+    lost
+  * fix for crashes on X11 displays lacking RandR support
+  * fix handling of non 24/32-bit png window icons
+  * man page connection string fixes
+  * disable cpuinfo module - known to cause problems on various
+    platforms
+  * ignore error and continue when loading version information
+    from invalid builds
+  * remove executable file permissions on files uploaded to the
+    server
+  * blacklist 'Intel(R) UHD Graphics 620'
+  * use correct location for appdata.xml
+  * use Debian location for systemd service config file
+  * ensure emacs, gvim and xxdiff always use 'text' mode
+  * re-enable pulseaudio memfd (was wrongly disabled in v3.0.0)
+  * remove remnants of GTK2 dependencies from non-GTK2 components
+  * add missing entry to path information tool
+
+- Refreshed xpra-paths.patch
+
+-------------------------------------------------------------------

Old:
----
  xpra-3.0.5.tar.xz

New:
----
  xpra-3.0.6.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ xpra.spec ++++++
--- /var/tmp/diff_new_pack.DwatAp/_old  2020-02-10 21:54:46.794235980 +0100
+++ /var/tmp/diff_new_pack.DwatAp/_new  2020-02-10 21:54:46.798235982 +0100
@@ -19,7 +19,7 @@
 
 %global __requires_exclude 
^typelib\\(GtkosxApplication\\)|typelib\\(GdkGLExt\\)|typelib\\(GtkGLExt\\).*$
 Name:           xpra
-Version:        3.0.5
+Version:        3.0.6
 Release:        0
 Summary:        Remote display server for applications and desktops
 License:        GPL-2.0-or-later AND BSD-3-Clause AND LGPL-3.0-or-later AND MIT
@@ -111,8 +111,7 @@
 connections, and also the xpra html5 client.
 
 %prep
-%setup -q
-%patch0 -p1
+%autosetup -p1
 # fix shebangs
 find -name '*.py' \
      -exec sed -i '1{\@^#!/usr/bin/env python@d}' {} +
@@ -143,6 +142,7 @@
     --skip-build \
     --root %{buildroot} \
     --prefix %{_prefix} \
+    --with-service \
     --verbose
 
 #Install nvenc.keys file
@@ -205,11 +205,11 @@
 %{_sbindir}/rc%{name}
 %{python3_sitearch}/xpra
 %{python3_sitearch}/%{name}-%{version}-py%{python3_version}.egg-info
-%{_datadir}/appdata/xpra.appdata.xml
 %{_datadir}/applications/xpra-gui.desktop
 %{_datadir}/applications/xpra-launcher.desktop
 %{_datadir}/applications/xpra-shadow.desktop
 %{_datadir}/applications/xpra.desktop
+%{_datadir}/metainfo/xpra.appdata.xml
 %{_datadir}/pixmaps/xpra-mdns.png
 %{_datadir}/pixmaps/xpra-shadow.png
 %{_datadir}/pixmaps/xpra.png

++++++ xpra-3.0.5.tar.xz -> xpra-3.0.6.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/NEWS new/xpra-3.0.6/NEWS
--- old/xpra-3.0.5/NEWS 2020-01-08 12:52:06.000000000 +0100
+++ new/xpra-3.0.6/NEWS 2020-02-07 12:19:08.000000000 +0100
@@ -1,3 +1,39 @@
+v3.0.6 (2020-02-05)
+======================
+       -- fix UDP with Python3
+       -- fix key mapping issues with non-X11 clients and non-US layouts
+       -- fix notification logging errors during shutdown
+       -- fix window stacking order with html5 client and override redirect 
windows
+       -- fix png/P and png/L decoding
+       -- fix very slow startup on Debian due to missing libfakeXinerama
+       -- fix display scaling notification warning
+       -- fix errors generating the tray title string
+       -- fix missing webp modules in 'clean' build target
+       -- fix some special characters with HTML5 client
+       -- fix initiate-moveresize with multiple clients
+       -- fix keyboard layout detection with MS Windows 10 clients
+       -- fix control commands argument error handling
+       -- fix unit tests
+       -- fix window repaint issues: system tray, Python 2 non-opengl window 
spinners
+       -- fix server errors during client connection cleanup
+       -- fix spacebar and other characters with tablet input devices (ie: 
mobile browsers)
+       -- fix unhelpful backtraces when client application windows are lost
+       -- fix MS Windows packaging workarounds for TK
+       -- fix for crashes on X11 displays lacking RandR support
+       -- fix handling of non 24/32-bit png window icons
+       -- man page connection string fixes
+       -- disable cpuinfo module - known to cause problems on various platforms
+       -- ignore error and continue when loading version information from 
invalid builds
+       -- remove executable file permissions on files uploaded to the server
+       -- blacklist 'Intel(R) UHD Graphics 620'
+       -- use correct location for appdata.xml
+       -- use Debian location for systemd service config file
+       -- ensure emacs, gvim and xxdiff always use 'text' mode
+       -- re-enable pulseaudio memfd (was wrongly disabled in v3.0.0)
+       -- remove remnants of GTK2 dependencies from non-GTK2 components
+       -- add missing entry to path information tool
+
+
 v3.0.5 (2020-01-07)
 ======================
        -- fix missing undecorated opengl windows on win32 with GTK3 (correct 
fix)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/content-type/50_class.conf 
new/xpra-3.0.6/content-type/50_class.conf
--- old/xpra-3.0.5/content-type/50_class.conf   2019-09-24 15:53:53.000000000 
+0200
+++ new/xpra-3.0.6/content-type/50_class.conf   2020-01-25 11:03:50.000000000 
+0100
@@ -8,6 +8,9 @@
 class-instance:gedit=text
 class-instance:Mail=text
 class-instance:tkdiff=text
+class-instance:xxdiff=text
+class-instance:emacs=text
+class-instance:gvim=text
 
 class-instance:vlc=video
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/cups/xpraforwarder 
new/xpra-3.0.6/cups/xpraforwarder
--- old/xpra-3.0.5/cups/xpraforwarder   2019-12-27 13:18:18.000000000 +0100
+++ new/xpra-3.0.6/cups/xpraforwarder   2020-01-20 20:48:07.000000000 +0100
@@ -42,7 +42,7 @@
     from urllib.parse import urlparse, parse_qs
 
 
-__version__ = "3.0.5"
+__version__ = "3.0.6"
 
 
 #Writes a syslog entry (msg) at the default facility:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/html5/index.html 
new/xpra-3.0.6/html5/index.html
--- old/xpra-3.0.5/html5/index.html     2019-11-18 16:50:49.000000000 +0100
+++ new/xpra-3.0.6/html5/index.html     2020-02-07 12:19:08.000000000 +0100
@@ -687,14 +687,24 @@
                                        for (var i = 0, len = txt.length; i < 
len; i++) {
                                                var str = txt[i];
                                                var keycode = str.charCodeAt(0);
+                                               var keyname = str;
+                                               if (str in CHAR_TO_NAME) {
+                                                       keyname = 
CHAR_TO_NAME[str];
+                                                       if 
(keyname.includes("_")) {
+                                                               //ie: 
Thai_dochada
+                                                               var lang = 
keyname.split("_")[0];
+                                                               key_language = 
KEYSYM_TO_LAYOUT[lang];
+                                                               
client._check_browser_language(key_language);
+                                                       }
+                                               }
                                                try {
                                                        modifiers = [];
                                                        keyval = keycode;
                                                        group = 0;
-                                                       packet = ["key-action", 
client.topwindow, str, true, modifiers, keyval, str, keycode, group];
+                                                       packet = ["key-action", 
client.topwindow, keyname, true, modifiers, keyval, str, keycode, group];
                                                        cdebug("keyboard", 
packet);
                                                        client.send(packet);
-                                                       packet = ["key-action", 
client.topwindow, str, false, modifiers, keyval, str, keycode, group];
+                                                       packet = ["key-action", 
client.topwindow, keyname, false, modifiers, keyval, str, keycode, group];
                                                        cdebug("keyboard", 
packet);
                                                        client.send(packet);
                                                }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/html5/js/Client.js 
new/xpra-3.0.6/html5/js/Client.js
--- old/xpra-3.0.5/html5/js/Client.js   2019-12-29 17:24:22.000000000 +0100
+++ new/xpra-3.0.6/html5/js/Client.js   2020-01-20 20:48:07.000000000 +0100
@@ -822,6 +822,10 @@
                        }
                }
        }
+       if (keyname=="F11") {
+               this.debug("keyboard", "allowing default handler for", keyname);
+               return true;
+       }
        return false;
 }
 
@@ -846,10 +850,6 @@
        var kc;
        for(var keycode in CHARCODE_TO_NAME) {
                kc = parseInt(keycode);
-       }
-       if (keyname=="F11") {
-               this.debug("keyboard", "allowing default handler for", keyname);
-               allow_default = true;
                keycodes.push([kc, CHARCODE_TO_NAME[keycode], kc, 0, 0]);
        }
        //show("keycodes="+keycodes.toSource());
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/html5/js/Keycodes.js 
new/xpra-3.0.6/html5/js/Keycodes.js
--- old/xpra-3.0.5/html5/js/Keycodes.js 2019-09-24 15:53:54.000000000 +0200
+++ new/xpra-3.0.6/html5/js/Keycodes.js 2020-02-07 12:19:08.000000000 +0100
@@ -1621,6 +1621,7 @@
 };
 
 CHAR_TO_NAME = {
+       " "                                     : "space",
        };
 //console.debug("KEYSYM_TO_UNICODE=", KEYSYM_TO_UNICODE);
 for (var keysym in KEYSYM_TO_UNICODE) {
@@ -1736,6 +1737,11 @@
 for (i=1; i<=24; i++) {
        CHARCODE_TO_NAME[111+i] = "F"+i;
 }
+//overrides: only for 'de' layout?
+CHARCODE_TO_NAME[192] = "dead_circumflex"
+CHARCODE_TO_NAME[219] = "backtick"
+CHARCODE_TO_NAME[221] = "dead_acute"
+CHARCODE_TO_NAME[220] = "dead_circumflex"
 
 
 /**
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/html5/js/Utilities.js 
new/xpra-3.0.6/html5/js/Utilities.js
--- old/xpra-3.0.5/html5/js/Utilities.js        2019-12-27 13:18:18.000000000 
+0100
+++ new/xpra-3.0.6/html5/js/Utilities.js        2020-01-20 20:48:07.000000000 
+0100
@@ -10,7 +10,7 @@
 'use strict';
 
 var Utilities = {
-       VERSION : "3.0.5",
+       VERSION : "3.0.6",
 
        exc : function() {
                console.error.apply(console, arguments);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/html5/js/Window.js 
new/xpra-3.0.6/html5/js/Window.js
--- old/xpra-3.0.5/html5/js/Window.js   2019-09-24 15:53:54.000000000 +0200
+++ new/xpra-3.0.6/html5/js/Window.js   2020-01-20 20:48:07.000000000 +0100
@@ -419,7 +419,7 @@
                z = 0;
        }
        else if (this.override_redirect || this.client.server_is_desktop || 
this.client.server_is_shadow) {
-               z = 15000;
+               z = 30000;
        }
        else if (this.windowtype=="DROPDOWN" || this.windowtype=="TOOLTIP" ||
                        this.windowtype=="POPUP_MENU" || 
this.windowtype=="MENU" ||
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/man/xpra.1 new/xpra-3.0.6/man/xpra.1
--- old/xpra-3.0.5/man/xpra.1   2019-11-26 16:58:06.000000000 +0100
+++ new/xpra-3.0.6/man/xpra.1   2020-02-07 12:19:08.000000000 +0100
@@ -14,14 +14,14 @@
 .SH SYNOPSIS
 .PD 0
 .HP \w'xpra\ 'u
-\fBxpra\fP \fBstart\fP [\fI:DISPLAY\fP] | \fBxpra\fP \fBstart\fP 
\fIssh:HOST:DISPLAY\fP |
-\fBxpra\fP \fBstart-desktop\fP [\fI:DISPLAY\fP] | \fBxpra\fP 
\fBstart-desktop\fP \fIssh:HOST:DISPLAY\fP
+\fBxpra\fP \fBstart\fP [CONNECTIONSTRING] |
+\fBxpra\fP \fBstart-desktop\fP [CONNECTIONSTRING]
 [\fBOPTIONS..\fP]
 .HP
 \fBxpra\fP \fBattach\fP [CONNECTIONSTRING]
 [\fBOPTIONS..\fP]
 .HP
-\fBxpra\fP \fBshadow\fP [\fI:DISPLAY\fP] | \fIssh:[USER@]HOST[:DISPLAY]\fP
+\fBxpra\fP \fBshadow\fP [CONNECTIONSTRING]
 [\fBOPTIONS..\fP]
 .HP
 \fBxpra\fP \fBproxy\fP [\fI:DISPLAY\fP]
@@ -29,7 +29,7 @@
 .HP
 \fBxpra\fP \fBstop\fP | \fBxpra\fP \fBexit\fP | \fBxpra\fP \fBdetach\fP |
 \fBxpra\fP \fBscreenshot\fP \fIfilename\fP | \fBxpra\fP \fBversion\fP |
-\fBxpra\fP \fBinfo\fP [CONNECTIONSTRING]
+\fBxpra\fP \fBinfo\fP [CONNECTIONSTRING] |
 \fBxpra\fP \fBtop\fP [CONNECTIONSTRING]
 [\fBOPTIONS..\fP]
 .HP
@@ -49,10 +49,10 @@
 .HP
 \fBxpra\fP \fBlist-mdns\fP
 .HP
-\fBxpra\fP \fBupgrade\fP \fI:[DISPLAY]\fP [...any options accepted by
+\fBxpra\fP \fBupgrade\fP \fI[:DISPLAY]\fP [...any options accepted by
 \fBxpra start\fP...]
 .HP
-\fBxpra\fP \fBupgrade-desktop\fP \fI:[DISPLAY]\fP [...any options accepted by
+\fBxpra\fP \fBupgrade-desktop\fP \fI[:DISPLAY]\fP [...any options accepted by
 \fBxpra start-desktop\fP...]
 .PD
 .\" --------------------------------------------------------------------
@@ -105,7 +105,7 @@
 
 .P
 For backwards compatibility, SSH mode also supports the syntax:
-\fBssh:[USERNAME[:PASSWORD]@HOST:DISPLAY\fP but this form does not
+\fBssh:[USERNAME[:PASSWORD]@]HOST:DISPLAY\fP but this form does not
 support specifying the SSH port number.
 Older versions also used the form \fBprotocol:host:port\fP, but users
 are encouraged to move to a more standard URI format using \fB://\fP as
@@ -132,7 +132,7 @@
 The start child commands will inherit an environment tailored
 for running under xpra.
 .TP
-\fBxpra start\fP \fIssh:bigbox:7 --start=xterm\fP
+\fBxpra start\fP \fIssh://bigbox/7 --start=xterm\fP
 Start an xpra server on \fIbigbox\fP with an xterm in it,
 and connect to it.
 .TP
@@ -158,7 +158,7 @@
 Attach to the xpra server that is using local display number \fI:7\fP.
 Any apps running on that server will appear on your screen.
 .TP
-\fBxpra attach\fP \fIssh://foo@frodo:7\fP
+\fBxpra attach\fP \fIssh://foo@frodo/7\fP
 Use ssh to attach to the xpra server that is running on machine
 \fIfrodo\fP as user \fIfoo\fP and using display \fI:7\fP.
 Any apps running on that server will appear on your local screen.
@@ -217,7 +217,7 @@
 \fBxpra version\fP, \fBxpra info\fP, \fBxpra list\fP or \fBxpra screenshot\fP 
then you
 can use a display of the form
 \fB:\fP\fIDISPLAY\fP to refer to a server on the local host, or one of
-the form \fBssh:\fP\fI[USER@]HOST\fP\fB:\fP\fIDISPLAY\fP to refer to a server
+the form \fBssh://\fP\fI[USER@]HOST\fP\fB/\fP\fIDISPLAY\fP to refer to a server
 on a remote host; xpra will automatically connect to the remote host
 using \fBssh\fP(1).  Generally, if you have only one xpra session
 running on a machine (which you can verify by running \fBxpra list\fP
@@ -236,16 +236,15 @@
 \fB--bind-udp\fP=\fI[HOST]:PORT\fP,
 \fB--bind-ws\fP, \fB--bind-wss\fP or \fB--bind-vsock\fP option
 when started then you can also connect
-to it using a display of the form \fBtcp://HOST:PORT\fP,
-\fBudp://HOST:PORT\fP, \fBssl://HOST:PORT\fP,
-\fBws://HOST:PORT\fP, \fBwss://HOST:PORT\fP or \fBvsock://HOST:PORT\fP.
-(Notice that \fBssh:\fP takes an optional \fIdisplay\fP number,
-while those take a required \fIport\fP number.)
+to it using a display of the form \fBtcp://HOST:PORT[/DISPLAY]\fP,
+\fBudp://HOST:PORT[/DISPLAY]\fP, \fBssl://HOST:PORT[/DISPLAY]\fP,
+\fBws://HOST:PORT[/DISPLAY]\fP, \fBwss://HOST:PORT[/DISPLAY]\fP or
+\fBvsock://HOST:PORT[/DISPLAY]\fP.
 .\" --------------------------------------------------------------------
 .SH SUBCOMMANDS
 .SS xpra start
 This command starts a new xpra server, including any necessary setup.
-(When starting a remote server with the \fBssh:HOST:DISPLAY\fP syntax,
+(When starting a remote server with the \fBssh://HOST/DISPLAY\fP syntax,
 the new session will also be attached.)
 .SS xpra start-desktop
 Starts a nested X11 server, all child commands will be started in the
@@ -583,7 +582,7 @@
 This option can be specified multiple times to specify multiple
 socket locations.
 These sockets support local connections with the \fB:7\fP-style display
-address, and remote connections with the \fBssh://frodo:7\fP-style
+address, and remote connections with the \fBssh://frodo/7\fP-style
 display address.
 
 Local sockets may also process HTTP / Websocket connections
@@ -1512,7 +1511,7 @@
 .\" produces fine output in the terminal, at least:
 .RS
 .RS
-\fBxpra attach --ssh\fP=\fI"ssh -c arcfour" ssh://frodo:7\fP
+\fBxpra attach --ssh\fP=\fI"ssh -c arcfour" ssh://frodo/7\fP
 
 .RE
 \fINote:\fP Don't bother to enable ssh compression; this
@@ -1634,7 +1633,9 @@
 and each user may override those defaults by creating the file 
\fI.xpra/xpra.conf\fP.
 You can also split the options into multiple files by placing them
 in a \fIconf.d\fP directory with the \fI.conf\fP extension.
-Xpra uses the directory \fI~/.xpra\fP to store a number of files.
+Depending on OS and version,
+xpra uses the directory \fI~/.xpra\fP or \fI/run/<uid>/xpra\fP
+to store a number of files.
 (The examples below are given for the display \fI:7\fP.)
 .TP
 \fI~/.xpra/:7\fP
@@ -1675,5 +1676,5 @@
 Send any questions or bugs reports to http://xpra.org/trac/
 .\" --------------------------------------------------------------------
 .SH SEE ALSO
-\fBscreen\fP(1)
+\fBscreen\fP(1),
 \fBwinswitch_applet\fP(1)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/setup.py new/xpra-3.0.6/setup.py
--- old/xpra-3.0.5/setup.py     2019-12-26 20:48:04.000000000 +0100
+++ new/xpra-3.0.6/setup.py     2020-02-07 12:19:08.000000000 +0100
@@ -364,7 +364,7 @@
 
 external_excludes = [
                     #Tcl/Tk
-                    "Tkconstants", "Tkinter", "tcl",
+                    "Tkconstants", "tkinter", "tcl",
                     #PIL bits that import TK:
                     "PIL._tkinter_finder", "_imagingtk", "PIL._imagingtk", 
"ImageTk", "PIL.ImageTk", "FixTk",
                     #formats we don't use:
@@ -784,7 +784,7 @@
     #generates an actual config file from the template
     xvfb_command = detect_xorg_setup(install_dir)
     fake_xinerama = "no"
-    if POSIX and not OSX:
+    if POSIX and not OSX and not (is_Debian() or is_Ubuntu()):
         from xpra.x11.fakeXinerama import find_libfakeXinerama
         fake_xinerama = find_libfakeXinerama() or "auto"
     from xpra.platform.features import DEFAULT_ENV
@@ -938,8 +938,8 @@
                    "xpra/codecs/v4l2/pusher.c",
                    "xpra/codecs/v4l2/constants.pxi",
                    "xpra/codecs/libav_common/av_log.c",
-                   "xpra/codecs/webp/encode.c",
-                   "xpra/codecs/webp/decode.c",
+                   "xpra/codecs/webp/encoder.c",
+                   "xpra/codecs/webp/decoder.c",
                    "xpra/codecs/dec_avcodec2/decoder.c",
                    "xpra/codecs/csc_libyuv/colorspace_converter.cpp",
                    "xpra/codecs/csc_swscale/colorspace_converter.c",
@@ -1503,7 +1503,7 @@
         add_data_files("share/applications",  glob.glob("xdg/*.desktop"))
         add_data_files("share/mime/packages", 
["xdg/application-x-xpraconfig.xml"])
         add_data_files("share/icons",         ["xdg/xpra.png", 
"xdg/xpra-mdns.png", "xdg/xpra-shadow.png"])
-        add_data_files("share/appdata",       ["xdg/xpra.appdata.xml"])
+        add_data_files("share/metainfo",      ["xdg/xpra.appdata.xml"])
 
     #here, we override build and install so we can
     #generate our /etc/xpra/xpra.conf
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/svn-info new/xpra-3.0.6/svn-info
--- old/xpra-3.0.5/svn-info     2020-01-08 12:52:13.000000000 +0100
+++ new/xpra-3.0.6/svn-info     2020-02-07 12:24:52.000000000 +0100
@@ -4,10 +4,10 @@
 Relative URL: ^/tags/v3.0.x/src
 Repository Root: file:///var/svn/repos/Xpra
 Repository UUID: 3bb7dfac-3a0b-4e04-842a-767bc560f471
-Revision: 24930
+Revision: 25177
 Node Kind: directory
 Schedule: normal
 Last Changed Author: antoine
-Last Changed Rev: 24930
-Last Changed Date: 2020-01-08 09:46:48 +0000 (Wed, 08 Jan 2020)
+Last Changed Rev: 25156
+Last Changed Date: 2020-02-05 12:06:46 +0000 (Wed, 05 Feb 2020)
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/svn-version new/xpra-3.0.6/svn-version
--- old/xpra-3.0.5/svn-version  2020-01-08 12:52:13.000000000 +0100
+++ new/xpra-3.0.6/svn-version  2020-02-07 12:24:52.000000000 +0100
@@ -1 +1 @@
-24930
+25177
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/xpra-3.0.5/unittests/unit/server/mixins/audio_test.py 
new/xpra-3.0.6/unittests/unit/server/mixins/audio_test.py
--- old/xpra-3.0.5/unittests/unit/server/mixins/audio_test.py   2019-09-24 
15:53:57.000000000 +0200
+++ new/xpra-3.0.6/unittests/unit/server/mixins/audio_test.py   2020-02-07 
12:19:08.000000000 +0100
@@ -26,6 +26,7 @@
         opts.pulseaudio = False
         opts.pulseaudio_command = "/bin/true"
         opts.pulseaudio_configure_commands = []
+        opts.av_sync = True
         self._test_mixin_class(AudioServer, opts, {
             "sound.receive" : True,
             "sound.decoders" : CODEC_ORDER,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/win32/xpra.iss 
new/xpra-3.0.6/win32/xpra.iss
--- old/xpra-3.0.5/win32/xpra.iss       2019-12-27 13:18:18.000000000 +0100
+++ new/xpra-3.0.6/win32/xpra.iss       2020-01-20 20:48:07.000000000 +0100
@@ -1,9 +1,9 @@
 [Setup]
 AppName=Xpra
 AppId=Xpra_is1
-AppVersion=3.0.5
-AppVerName=Xpra 3.0.5
-UninstallDisplayName=Xpra 3.0.5
+AppVersion=3.0.6
+AppVerName=Xpra 3.0.6
+UninstallDisplayName=Xpra 3.0.6
 AppPublisher=xpra.org
 AppPublisherURL=http:;xpra.org/
 DefaultDirName={pf}\Xpra
@@ -16,7 +16,7 @@
 Compression=lzma2/max
 SolidCompression=yes
 AllowUNCPath=false
-VersionInfoVersion=3.0.5
+VersionInfoVersion=3.0.6
 VersionInfoCompany=xpra.org
 VersionInfoDescription=multi-platform screen and application forwarding system
 WizardImageFile=win32\xpra-logo.bmp
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/__init__.py 
new/xpra-3.0.6/xpra/__init__.py
--- old/xpra-3.0.5/xpra/__init__.py     2020-01-08 12:52:17.000000000 +0100
+++ new/xpra-3.0.6/xpra/__init__.py     2020-02-07 12:24:56.000000000 +0100
@@ -4,4 +4,4 @@
 # Xpra is released under the terms of the GNU GPL v2, or, at your option, any
 # later version. See the file COPYING for details.
 
-__version__ = "3.0.5"
+__version__ = "3.0.6"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/client/gl/gl_drivers.py 
new/xpra-3.0.6/xpra/client/gl/gl_drivers.py
--- old/xpra-3.0.5/xpra/client/gl/gl_drivers.py 2019-11-05 18:31:07.000000000 
+0100
+++ new/xpra-3.0.6/xpra/client/gl/gl_drivers.py 2020-01-25 11:03:51.000000000 
+0100
@@ -29,6 +29,7 @@
             "Software Rasterizer",
             "Mesa DRI Intel(R) Ivybridge Desktop",
             "Mesa DRI Intel(R) Haswell Mobile",
+            "Intel(R) UHD Graphics 620",
         ],
     "vendor"    : [
         #"VMware, Inc.",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/xpra-3.0.5/xpra/client/gtk_base/gtk_client_window_base.py 
new/xpra-3.0.6/xpra/client/gtk_base/gtk_client_window_base.py
--- old/xpra-3.0.5/xpra/client/gtk_base/gtk_client_window_base.py       
2020-01-08 12:52:06.000000000 +0100
+++ new/xpra-3.0.6/xpra/client/gtk_base/gtk_client_window_base.py       
2020-02-07 12:19:08.000000000 +0100
@@ -1676,7 +1676,10 @@
         if is_gtk3():
             context.rectangle(0, 0, w, h)
         else:
-            context.rectangle(gdk.Rectangle(0, 0, w, h))
+            rect = gdk.Rectangle()
+            rect.width = w
+            rect.height = h
+            context.rectangle(rect)
         context.fill()
         #add spinner:
         dim = min(w/3.0, h/3.0, 100.0)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/client/mixins/display.py 
new/xpra-3.0.6/xpra/client/mixins/display.py
--- old/xpra-3.0.5/xpra/client/mixins/display.py        2019-12-08 
12:59:03.000000000 +0100
+++ new/xpra-3.0.6/xpra/client/mixins/display.py        2020-01-20 
20:48:07.000000000 +0100
@@ -550,7 +550,7 @@
                 "the scaled client screen %i x %i -> %i x %i" % (root_w, 
root_h, sw, sh),
                 " would overflow the server's screen: %i x %i" % (maxw, maxh),
                 ]
-            self.may_notify(XPRA_SCALING_NOTIFICATION_ID, summary, 
"\n".join(messages), "scaling")
+            self.may_notify(XPRA_SCALING_NOTIFICATION_ID, summary, 
"\n".join(messages), icon_name="scaling")
             scalinglog.warn("Warning: %s", summary)
             for m in messages:
                 scalinglog.warn(" %s", m)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/client/mixins/tray.py 
new/xpra-3.0.6/xpra/client/mixins/tray.py
--- old/xpra-3.0.5/xpra/client/mixins/tray.py   2019-12-29 17:24:22.000000000 
+0100
+++ new/xpra-3.0.6/xpra/client/mixins/tray.py   2020-01-20 20:48:07.000000000 
+0100
@@ -135,6 +135,6 @@
                 t.append(cinfo.get("endpoint", bytestostr(conn.target)))
         if not t:
             t.insert(0, u"Xpra")
-        v = u"\n".join(t)
+        v = u"\n".join(str(x) for x in t)
         log("get_tray_title()=%s (items=%s)", nonl(v), tuple(strtobytes(x) for 
x in t))
         return v
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/client/mixins/window_manager.py 
new/xpra-3.0.6/xpra/client/mixins/window_manager.py
--- old/xpra-3.0.5/xpra/client/mixins/window_manager.py 2019-11-21 
08:29:31.000000000 +0100
+++ new/xpra-3.0.6/xpra/client/mixins/window_manager.py 2020-02-07 
12:19:09.000000000 +0100
@@ -666,7 +666,8 @@
         else:
             from xpra.codecs.pillow.decoder import open_only
             img = open_only(data, ("png", ))
-            assert img.mode in ("RGB", "RGBA"), "invalid image mode: %s" % 
img.mode
+            if img.mode not in ("RGB", "RGBA"):
+                img = img.convert("RGBA")
             has_alpha = img.mode=="RGBA"
             rowstride = width * (3+int(has_alpha))
         icon = img
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/codecs/pillow/decoder.py 
new/xpra-3.0.6/xpra/codecs/pillow/decoder.py
--- old/xpra-3.0.5/xpra/codecs/pillow/decoder.py        2019-09-24 
15:53:59.000000000 +0200
+++ new/xpra-3.0.6/xpra/codecs/pillow/decoder.py        2020-01-20 
20:48:07.000000000 +0100
@@ -97,7 +97,7 @@
 def decompress(coding, img_data, options):
     # can be called from any thread
     actual = get_image_type(img_data)
-    if actual!=coding:
+    if not actual or not coding.startswith(actual):
         raise Exception("expected %s image data but received %s" % (coding, 
actual or "unknown"))
     buf = BytesIO(img_data)
     img = Image.open(buf)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/keyboard/layouts.py 
new/xpra-3.0.6/xpra/keyboard/layouts.py
--- old/xpra-3.0.5/xpra/keyboard/layouts.py     2019-09-24 15:53:59.000000000 
+0200
+++ new/xpra-3.0.6/xpra/keyboard/layouts.py     2020-01-25 11:03:51.000000000 
+0100
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # This file is part of Xpra.
-# Copyright (C) 2011-2013 Antoine Martin <anto...@xpra.org>
+# Copyright (C) 2011-2020 Antoine Martin <anto...@xpra.org>
 # Xpra is released under the terms of the GNU GPL v2, or, at your option, any
 # later version. See the file COPYING for details.
 
@@ -164,6 +164,211 @@
            58380: ("",    "North Africa",  "French",                   1252,   
"fr", FR_VARIANTS),
            }
 
+#map win32 keyboard codes to x11 names:
+#based on
+#https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/windows-language-pack-default-values
+WIN32_KEYBOARDS = {
+    0x0000041c  : ("al", "Albania"),
+    0x00000401  : ("ar", "Arabic (101)"),
+    0x00010401  : ("ar", "Arabic (102)"),
+    0x00020401  : ("ar", "Arabic (102) AZERTY"),
+    0x0000042b  : ("am", "Armenian Eastern"),
+    0x0002042b  : ("am", "Armenian Phonetic"),
+    0x0003042b  : ("am", "Armenian Typewriter"),
+    0x0001042b  : ("am", "Armenian Western"),
+    0x0000044d  : ("in", "Assamese - Inscript"),
+    0x0001042c  : ("az", "Azerbaijani (Standard)"),
+    0x0000082c  : ("az", "Azerbaijani Cyrillic"),
+    0x0000042c  : ("az", "Azerbaijani Latin"),
+    0x0000046d  : ("ru", "Bashkir"),
+    0x00000423  : ("by", "Belarusian"),
+    0x0001080c  : ("be", "Belgian (Comma)"),
+    0x00000813  : ("be", "Belgian (Period)"),
+    0x0000080c  : ("be", "Belgian French"),
+    0x00000445  : ("bd", "Bangla (Bangladesh)"),
+    0x00020445  : ("bd", "Bangla (India)"),
+    0x00010445  : ("bd", "Bangla (India - Legacy)"),
+    0x0000201a  : ("ba", "Bosnian (Cyrillic)"),
+    0x000b0c00  : ("??", "Buginese"),
+    0x00030402  : ("bg", "Bulgarian"),
+    0x00010402  : ("bg", "Bulgarian (Latin)"),
+    0x00020402  : ("bg", "Bulgarian (phonetic layout)"),
+    0x00040402  : ("bg", "Bulgarian (phonetic traditional)"),
+    0x00000402  : ("bg", "Bulgarian (Typewriter)"),
+    0x00001009  : ("ca", "Canadian French"),
+    0x00000c0c  : ("ca", "Canadian French (Legacy)"),
+    0x00011009  : ("ca", "Canadian Multilingual Standard"),
+    0x0000085f  : ("fr", "Central Atlas Tamazight"),
+    0x00000429  : ("ku", "Central Kurdish"),
+    0x0000045c  : ("us", "Cherokee Nation"),
+    0x0001045c  : ("us", "Cherokee Nation Phonetic"),
+    0x00000804  : ("cn", "Chinese (Simplified) - US Keyboard"),
+    0x00000404  : ("cn", "Chinese (Traditional) - US Keyboard"),
+    0x00000c04  : ("cn", "Chinese (Traditional, Hong Kong S.A.R.)"),
+    0x00001404  : ("cn", "Chinese (Traditional Macao S.A.R.) US Keyboard"),
+    0x00001004  : ("cn", "Chinese (Simplified, Singapore) - US keyboard"),
+    0x0000041a  : ("hr", "Croatian"),
+    0x00000405  : ("cz", "Czech"),
+    0x00010405  : ("cz", "Czech (QWERTY)"),
+    0x00020405  : ("cz", "Czech Programmers"),
+    0x00000406  : ("dk", "Danish"),
+    0x00000439  : ("in", "Devanagari-INSCRIPT"),
+    0x00000465  : ("in", "Divehi Phonetic"),
+    0x00010465  : ("in", "Divehi Typewriter"),
+    0x00000413  : ("nl", "Dutch"),
+    0x00000C51  : ("dz", "Dzongkha"),
+    0x00000425  : ("ee", "Estonian"),
+    0x00000438  : ("fo", "Faeroese"),
+    0x0000040b  : ("fi", "Finnish"),
+    0x0001083b  : ("fi", "Finnish with Sami"),
+    0x0000040c  : ("fr", "French"),
+    0x00120c00  : ("??", "Futhark"),
+    0x00000437  : ("ge", "Georgian"),
+    0x00020437  : ("ge", "Georgian (Ergonomic)"),
+    0x00010437  : ("ge", "Georgian (QWERTY)"),
+    0x00030437  : ("ge", "Georgian Ministry of Education and Science Schools"),
+    0x00040437  : ("ge", "Georgian (Old Alphabets)"),
+    0x00000407  : ("de", "German"),
+    0x00010407  : ("de", "German (IBM)"),
+    0x000c0c00  : ("??", "Gothic"),
+    0x00000408  : ("gr", "Greek"),
+    0x00010408  : ("gr", "Greek (220)"),
+    0x00030408  : ("gr", "Greek (220) Latin"),
+    0x00020408  : ("gr", "Greek (319)"),
+    0x00040408  : ("gr", "Greek (319) Latin"),
+    0x00050408  : ("gr", "Greek Latin"),
+    0x00060408  : ("gr", "Greek Polytonic"),
+    0x0000046f  : ("??", "Greenlandic"),
+    0x00000474  : ("??", "Guarani"),
+    0x00000447  : ("in", "Gujarati"),
+    0x00000468  : ("gh", "Hausa"),
+    0x0000040d  : ("il", "Hebrew"),
+    0x00010439  : ("in", "Hindi Traditional"),
+    0x0000040e  : ("hu", "Hungarian"),
+    0x0001040e  : ("hu", "Hungarian 101-key"),
+    0x0000040f  : ("is", "Icelandic"),
+    0x00000470  : ("ng", "Igbo"),
+    0x00004009  : ("in", "India"),
+    0x0000085d  : ("ca", "Inuktitut - Latin"),
+    0x0001045d  : ("ca", "Inuktitut - Naqittaut"),
+    0x00001809  : ("ie", "Ireland"),
+    0x00000410  : ("it", "Italian"),
+    0x00010410  : ("it", "Italian"),
+    0x00000411  : ("jp", "Japanese"),
+    0x00110c00  : ("??", "Javanese"),
+    0x0000044b  : ("in", "Kannada"),
+    0x0000043f  : ("kz", "Kazakh"),
+    0x00000453  : ("kh", "Khmer"),
+    0x00010453  : ("kh", "Khmer (NIDA)"),
+    0x00000412  : ("kr", "Korean"),
+    0x00000440  : ("kg", "Kyrgyz Cyrillic"),
+    0x00000454  : ("la", "Lao"),
+    0x0000080a  : ("latam", "Latin American"),
+    0x00020426  : ("lv", "Latvian (Standard)"),
+    0x00010426  : ("lv", "Latvian (Legacy)"),
+    0x00070c00  : ("??", "Lisu (Basic)"),
+    0x00080c00  : ("??", "Lisu (Standard)"),
+    0x00010427  : ("lt", "Lithuanian"),
+    0x00000427  : ("lt", "Lithuanian IBM"),
+    0x00020427  : ("lt", "Lithuanian Standard"),
+    0x0000046e  : ("de", "Luxembourgish"),
+    0x0000042f  : ("mk", "Macedonia (FYROM)"),
+    0x0001042f  : ("mk", "Macedonia (FYROM) - Standard"),
+    0x0000044c  : ("in", "Malayalam"),
+    0x0000043a  : ("mt", "Maltese 47-Key"),
+    0x0001043a  : ("mt", "Maltese 48-key"),
+    0x00000481  : ("mao", "Maori"),
+    0x0000044e  : ("in", "Marathi"),
+    0x00000850  : ("mn", "Mongolian (Mongolian Script - Legacy)"),
+    0x00020850  : ("mn", "Mongolian (Mongolian Script - Standard)"),
+    0x00000450  : ("mn", "Mongolian Cyrillic"),
+    0x00010c00  : ("mm", "Myanmar"),
+    0x00090c00  : ("??", "N'ko"),
+    0x00000461  : ("np", "Nepali"),
+    0x00020c00  : ("th", "New Tai Lue"),
+    0x00000414  : ("no", "Norwegian"),
+    0x0000043b  : ("no", "Norwegian with Sami"),
+    0x00000448  : ("in", "Odia"),
+    0x000d0c00  : ("in", "Ol Chiki"),
+    0x000f0c00  : ("??", "Old Italic"),
+    0x000e0c00  : ("??", "Osmanya"),
+    0x00000463  : ("af", "Pashto (Afghanistan)"),
+    0x00000429  : ("ir", "Persian"),
+    0x00050429  : ("ir", "Persian (Standard)"),
+    0x000a0c00  : ("cn", "Phags-pa"),
+    0x00010415  : ("pl", "Polish (214)"),
+    0x00000415  : ("pl", "Polish (Programmers)"),
+    0x00000816  : ("pt", "Portuguese"),
+    0x00000416  : ("pt", "Portuguese (Brazilian ABNT),"),
+    0x00010416  : ("pt", "Portuguese (Brazilian ABNT2)"),
+    0x00000446  : ("in", "Punjabi"),
+    0x00000418  : ("ro", "Romanian (Legacy)"),
+    0x00020418  : ("ro", "Romanian (Programmers)"),
+    0x00010418  : ("ro", "Romanian (Standard)"),
+    0x00000419  : ("ru", "Russian"),
+    0x00020419  : ("ru", "Russian - Mnemonic"),
+    0x00010419  : ("ru", "Russian (Typewriter)"),
+    0x00000485  : ("ru", "Sakha"),
+    0x0002083b  : ("fi", "Sami Extended Finland-Sweden"),
+    0x0001043b  : ("no", "Sami Extended Norway"),
+    0x00011809  : ("gb", "Scottish Gaelic"),
+    0x00000c1a  : ("ru", "Serbian (Cyrillic)"),
+    0x0000081a  : ("rs", "Serbian (Latin)"),
+    0x0000046c  : ("za", "Sesotho sa Leboa"),
+    0x00000432  : ("za", "Setswana"),
+    0x0000045b  : ("in", "Sinhala"),
+    0x0001045b  : ("in", "Sinhala - wij 9"),
+    0x0000041b  : ("sk", "Slovak"),
+    0x0001041b  : ("sk", "Slovak (QWERTY)"),
+    0x00000424  : ("si", "Slovenian"),
+    0x00100c00  : ("in", "Sora"),
+    0x0001042e  : ("de", "Sorbian Extended"),
+    0x0002042e  : ("de", "Sorbian Standard"),
+    0x0000042e  : ("de", "Sorbian Standard (Legacy)"),
+    0x0000040a  : ("es", "Spanish"),
+    0x0001040a  : ("es", "Spanish Variation"),
+    0x0000041d  : ("se", "Swedish"),
+    0x0000083b  : ("se", "Swedish with Sami"),
+    0x0000100c  : ("fr", "Swiss French"),
+    0x00000807  : ("de", "Swiss German"),
+    0x0000045a  : ("sy", "Syriac"),
+    0x0001045a  : ("sy", "Syriac Phonetic"),
+    0x00030c00  : ("cn", "Tai Le"),
+    0x00000428  : ("tj", "Tajik"),
+    0x00000449  : ("in", "Tamil"),
+    0x00010444  : ("ru", "Tatar"),
+    0x00000444  : ("ru", "Tatar (Legacy)"),
+    0x0000044a  : ("in", "Telugu"),
+    0x0000041e  : ("th", "Thai Kedmanee"),
+    0x0002041e  : ("th", "Thai Kedmanee (non-ShiftLock)"),
+    0x0001041e  : ("th", "Thai Pattachote"),
+    0x0003041e  : ("th", "Thai Pattachote (non-ShiftLock)"),
+    0x00010451  : ("cn", "Tibetan (PRC - Standard)"),
+    0x00000451  : ("cn", "Tibetan (PRC - Legacy)"),
+    0x00050c00  : ("ma", "Tifinagh (Basic)"),
+    0x00060c00  : ("ma", "Tifinagh (Full)"),
+    0x0001041f  : ("tr", "Turkish F"),
+    0x0000041f  : ("tr", "Turkish Q"),
+    0x00000442  : ("tm", "Turkmen"),
+    0x00010408  : ("tr", "Uyghur    "),
+    0x00000480  : ("tr", "Uyghur (Legacy)"),
+    0x00000422  : ("ua", "Ukrainian"),
+    0x00020422  : ("ua", "Ukrainian (Enhanced)"),
+    0x00000809  : ("gb", "United Kingdom"),
+    0x00000452  : ("gb", "United Kingdom Extended"),
+    0x00010409  : ("us", "United States - Dvorak"),
+    0x00020409  : ("us", "United States - International"),
+    0x00030409  : ("us", "United States-Dvorak for left hand"),
+    0x00040409  : ("us", "United States-Dvorak for right hand"),
+    0x00000409  : ("us", "United States - English"),
+    0x00000420  : ("in", "Urdu"),
+    0x00000843  : ("ru", "Uzbek Cyrillic"),
+    0x0000042a  : ("vn", "Vietnamese"),
+    0x00000488  : ("fr", "Wolof"),
+    0x00000485  : ("tr", "Yakut"),
+    0x0000046a  : ("??", "Yoruba"),
+    }
+
 # This is generated from the table above so we can
 # let the user choose his own layout.
 # (country,language) : (layout,variant)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/net/file_transfer.py 
new/xpra-3.0.6/xpra/net/file_transfer.py
--- old/xpra-3.0.5/xpra/net/file_transfer.py    2019-10-21 13:03:51.000000000 
+0200
+++ new/xpra-3.0.6/xpra/net/file_transfer.py    2020-01-25 11:03:51.000000000 
+0100
@@ -10,7 +10,7 @@
 import uuid
 
 from xpra.child_reaper import getChildReaper
-from xpra.os_util import monotonic_time, bytestostr, strtobytes, POSIX, WIN32
+from xpra.os_util import monotonic_time, bytestostr, strtobytes, 
umask_context, POSIX, WIN32
 from xpra.util import typedict, csv, nonl, envint, envbool, engs
 from xpra.scripts.config import parse_bool
 from xpra.simple_stats import std_unit
@@ -77,7 +77,8 @@
         flags |= os.O_BINARY                #@UndefinedVariable (win32 only)
     except AttributeError:
         pass
-    fd = os.open(filename, flags)
+    with umask_context(0o133):
+        fd = os.open(filename, flags)
     filelog("using filename '%s', file descriptor=%s", filename, fd)
     return filename, fd
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/net/protocol.py 
new/xpra-3.0.6/xpra/net/protocol.py
--- old/xpra-3.0.5/xpra/net/protocol.py 2019-09-29 11:13:19.000000000 +0200
+++ new/xpra-3.0.6/xpra/net/protocol.py 2020-01-20 20:48:07.000000000 +0100
@@ -332,7 +332,7 @@
                 self._read_thread.start()
         self.idle_add(start_network_read_thread)
         if SEND_INVALID_PACKET:
-            self.timeout_add(SEND_INVALID_PACKET*1000, self.raw_write, 
SEND_INVALID_PACKET_DATA)
+            self.timeout_add(SEND_INVALID_PACKET*1000, self.raw_write, 
"invalid", SEND_INVALID_PACKET_DATA)
 
 
     def send_disconnect(self, reasons, done_callback=None):
@@ -448,7 +448,7 @@
                 items[0] = frame_header + item0
             else:
                 items.insert(0, frame_header)
-        self.raw_write(items, start_send_cb, end_send_cb, fail_cb, 
synchronous, more)
+        self.raw_write(packet_type, items, start_send_cb, end_send_cb, 
fail_cb, synchronous, more)
 
     def make_xpra_header(self, _packet_type, proto_flags, level, index, 
payload_size):
         return pack_header(proto_flags, level, index, payload_size)
@@ -460,7 +460,7 @@
     def start_write_thread(self):
         self._write_thread = start_thread(self._write_thread_loop, "write", 
daemon=True)
 
-    def raw_write(self, items, start_cb=None, end_cb=None, fail_cb=None, 
synchronous=True, more=False):
+    def raw_write(self, packet_type, items, start_cb=None, end_cb=None, 
fail_cb=None, synchronous=True, more=False):
         """ Warning: this bypasses the compression and packet encoder! """
         if self._write_thread is None:
             self.start_write_thread()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/net/subprocess_wrapper.py 
new/xpra-3.0.6/xpra/net/subprocess_wrapper.py
--- old/xpra-3.0.5/xpra/net/subprocess_wrapper.py       2019-09-24 
15:54:00.000000000 +0200
+++ new/xpra-3.0.6/xpra/net/subprocess_wrapper.py       2020-01-20 
20:48:07.000000000 +0100
@@ -45,7 +45,7 @@
         _counter += 1
         if (_counter % FAULT_RATE)==0:
             log.warn("injecting fault in %s", p)
-            p.raw_write("Wrapper JUNK! added by fault injection code")
+            p.raw_write("junk", "Wrapper JUNK! added by fault injection code")
     INJECT_FAULT = DO_INJECT_FAULT
 
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/net/udp_protocol.py 
new/xpra-3.0.6/xpra/net/udp_protocol.py
--- old/xpra-3.0.5/xpra/net/udp_protocol.py     2019-09-24 15:54:00.000000000 
+0200
+++ new/xpra-3.0.6/xpra/net/udp_protocol.py     2020-01-20 20:48:07.000000000 
+0100
@@ -181,7 +181,7 @@
             #resend a new one
             self.cancel_control_timer()
             self.send_control()
-        self._send_async(packet, False, send_control_failed)
+        self._add_packet_to_queue(packet, fail_cb=self.send_control_failed, 
synchronous=False)
         self.cancel = set()
         self.schedule_control()
         return False
@@ -411,29 +411,11 @@
             self._read_queue_put(data)
 
 
-    def _send_async(self, packet, sync=False, fail_cb=None):
-        """ used by send_control to bypass the regular queuing functions,
-            and force enable synchronous=False
-        """
-        #log("_send_async(%s, %s) encoder=%s, compressor=%s", packet, sync, 
self._encoder, self._compress)
-        log("_send_async(%s, %s)", packet, sync)
-        chunks = self.encode(packet)
-        if len(chunks)>1:
-            return Protocol.send_now(self, packet)
-        proto_flags,index,level,data = chunks[0]
-        from xpra.net.header import pack_header
-        payload_size = len(data)
-        header_and_data = pack_header(proto_flags, level, index, payload_size) 
+ data
-        with self._write_lock:
-            if self._write_thread is None:
-                self.start_write_thread()
-            self._write_queue.put((header_and_data, None, None, fail_cb, sync))
-
-    def raw_write(self, items, start_cb=None, end_cb=None, fail_cb=None, 
synchronous=True, _more=False):
+    def raw_write(self, packet_type, items, start_cb=None, end_cb=None, 
fail_cb=None, synchronous=True, _more=False):
         """ make sure we don't enable asynchronous mode until the other end is 
read """
-        if not self.asynchronous_send_enabled:
+        if packet_type!="udp-control" and not self.asynchronous_send_enabled:
             synchronous = True
-        Protocol.raw_write(self, items, start_cb, end_cb, fail_cb, synchronous)
+        Protocol.raw_write(self, packet_type, items, start_cb, end_cb, 
fail_cb, synchronous)
 
     def write_buffers(self, buf_data, fail_cb, synchronous):
         """
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/net/websockets/protocol.py 
new/xpra-3.0.6/xpra/net/websockets/protocol.py
--- old/xpra-3.0.5/xpra/net/websockets/protocol.py      2019-09-24 
15:54:00.000000000 +0200
+++ new/xpra-3.0.6/xpra/net/websockets/protocol.py      2020-01-20 
20:48:07.000000000 +0100
@@ -169,7 +169,7 @@
         item = encode_hybi_header(OPCODE_PONG, len(payload)) + 
memoryview_to_bytes(payload)
         items = (item, )
         with self._write_lock:
-            self.raw_write(items)
+            self.raw_write("ws-ping", items)
 
     def _process_ws_pong(self, payload):
         log("_process_ws_pong(%r)", payload)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/platform/darwin/keyboard_config.py 
new/xpra-3.0.6/xpra/platform/darwin/keyboard_config.py
--- old/xpra-3.0.5/xpra/platform/darwin/keyboard_config.py      2019-09-24 
15:54:00.000000000 +0200
+++ new/xpra-3.0.6/xpra/platform/darwin/keyboard_config.py      2020-01-25 
11:03:51.000000000 +0100
@@ -23,7 +23,7 @@
         return []
 
 
-    def do_get_keycode(self, client_keycode, keyname, pressed, modifiers):
+    def do_get_keycode(self, client_keycode, keyname, pressed, modifiers, 
group):
         global KEYCODES
         keycode = KEYCODES.get(keyname, -1)
         if keycode==-1:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/platform/paths.py 
new/xpra-3.0.6/xpra/platform/paths.py
--- old/xpra-3.0.5/xpra/platform/paths.py       2019-09-24 15:54:00.000000000 
+0200
+++ new/xpra-3.0.6/xpra/platform/paths.py       2020-01-20 20:48:07.000000000 
+0100
@@ -304,6 +304,7 @@
         "xpra-module"       : XPRA_MODULE_PATH,
         "app"               : {"default" : {"dir"   : default_get_app_dir()}},
         "desktop-background": get_desktop_background_paths(),
+        "ssh-known-hosts"   : get_ssh_known_hosts_files(),
         "resources"         : get_resources_dir(),
         "icons"             : get_icon_dir(),
         "home"              : os.path.expanduser("~"),
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/platform/win32/common.py 
new/xpra-3.0.6/xpra/platform/win32/common.py
--- old/xpra-3.0.5/xpra/platform/win32/common.py        2019-09-24 
15:54:00.000000000 +0200
+++ new/xpra-3.0.6/xpra/platform/win32/common.py        2020-01-25 
11:03:51.000000000 +0100
@@ -302,6 +302,9 @@
 GetKeyboardLayout = user32.GetKeyboardLayout
 GetKeyboardLayoutList = user32.GetKeyboardLayoutList
 GetKeyboardLayoutList.argtypes = [c_int, POINTER(HANDLE*32)]
+GetKeyboardLayoutName = user32.GetKeyboardLayoutNameA
+GetKeyboardLayoutName.restype = BOOL
+GetKeyboardLayoutName.argtypes = [LPSTR]
 SystemParametersInfoA = user32.SystemParametersInfoA
 EnumWindows = user32.EnumWindows
 EnumWindowsProc = WINFUNCTYPE(BOOL, HWND, LPARAM)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/platform/win32/keyboard.py 
new/xpra-3.0.6/xpra/platform/win32/keyboard.py
--- old/xpra-3.0.5/xpra/platform/win32/keyboard.py      2019-09-24 
15:54:00.000000000 +0200
+++ new/xpra-3.0.6/xpra/platform/win32/keyboard.py      2020-01-25 
11:03:51.000000000 +0100
@@ -1,19 +1,21 @@
 # This file is part of Xpra.
 # Copyright (C) 2010 Nathaniel Smith <n...@pobox.com>
-# Copyright (C) 2011-2017 Antoine Martin <anto...@xpra.org>
+# Copyright (C) 2011-2020 Antoine Martin <anto...@xpra.org>
 # Xpra is released under the terms of the GNU GPL v2, or, at your option, any
 # later version. See the file COPYING for details.
 
 import ctypes
 from ctypes.wintypes import HANDLE
 
-from xpra.platform.win32.common import GetKeyState, GetKeyboardLayoutList, 
GetKeyboardLayout, GetIntSystemParametersInfo
+from xpra.platform.win32.common import GetKeyState, GetKeyboardLayoutList, 
GetKeyboardLayout, GetIntSystemParametersInfo, GetKeyboardLayoutName
 from xpra.platform.win32 import constants as win32con
 from xpra.platform.keyboard_base import KeyboardBase
-from xpra.keyboard.layouts import WIN32_LAYOUTS
+from xpra.keyboard.layouts import WIN32_LAYOUTS, WIN32_KEYBOARDS
 from xpra.gtk_common.keymap import KEY_TRANSLATIONS
 from xpra.util import csv, envint, envbool
+from xpra.os_util import bytestostr
 from xpra.log import Logger
+from ctypes import create_string_buffer
 
 log = Logger("keyboard")
 
@@ -46,6 +48,7 @@
         self.num_lock_modifier = None
         self.altgr_modifier = None
         self.delayed_event = None
+        self.last_layout_message = None
         #workaround for "period" vs "KP_Decimal" with gtk2 (see ticket #586):
         #translate "period" with keyval=46 and keycode=110 to KP_Decimal:
         KEY_TRANSLATIONS[("period",     46,     110)]   = "KP_Decimal"
@@ -110,7 +113,39 @@
         return  {}, [], ["lock"]
 
     def get_layout_spec(self):
+        KL_NAMELENGTH = 9
+        name_buf = create_string_buffer(KL_NAMELENGTH)
         layout = None
+        if GetKeyboardLayoutName(name_buf):
+            log("get_layout_spec() GetKeyboardLayoutName()=%s", 
bytestostr(name_buf.value))
+            try:
+                #win32 API returns a hex string
+                ival = int(name_buf.value, 16)
+            except ValueError:
+                log.warn("Warning: failed to parse keyboard layout code '%s'", 
bytestostr(name_buf.value))
+            else:
+                found = False
+                for val in (ival, ival & 0xffff):
+                    kbdef = WIN32_KEYBOARDS.get(val)
+                    log("get_layout_spec() WIN32_KEYBOARDS[%#x]=%s", val, 
kbdef)
+                    if kbdef:
+                        found = True
+                        layout, descr = kbdef
+                        if layout=="??":
+                            log.warn("Warning: the X11 codename for %#x is not 
known", val)
+                            log.warn(" only identified as '%s'", descr)
+                            log.warn(" please file a bug report")
+                            layout = None
+                            continue
+                        if self.last_layout_message!=layout:
+                            log.info("keyboard layout code %#x", ival)
+                            log.info("identified as '%s' : %s", descr, layout)
+                            self.last_layout_message = layout
+                        break
+                if not found and self.last_layout_message!=layout:
+                    log.warn("Warning: unknown keyboard layout %#x", val)
+                    log.warn(" please file a bug report")
+                    self.last_layout_message = layout
         layouts = []
         variant = None
         variants = None
@@ -133,12 +168,15 @@
             log("GetKeyboardLayout(0)=%#x", hkl)
             kbid = hkl & 0xffff
             if kbid in WIN32_LAYOUTS:
-                code, _, _, _, layout, variants = WIN32_LAYOUTS.get(kbid)
-                log("found keyboard layout '%s' with variants=%s, code '%s' 
for kbid=%i (%#x)", layout, variants, code, kbid, hkl)
-            if not layout:
+                code, _, _, _, layout0, variants = WIN32_LAYOUTS.get(kbid)
+                log("found keyboard layout '%s' with variants=%s, code '%s' 
for kbid=%i (%#x)", layout0, variants, code, kbid, hkl)
+            if not layout0:
                 log("unknown keyboard layout for kbid: %i (%#x)", kbid, hkl)
-            else:
-                layouts.append(layout)
+            elif layout0 not in layouts:
+                layouts.append(layout0)
+            #only override "layout" if unset:
+            if not layout and layout0:
+                layout = layout0
         except Exception as e:
             log.error("Error: failed to detect keyboard layout:")
             log.error(" %s", e)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/platform/win32/keyboard_config.py 
new/xpra-3.0.6/xpra/platform/win32/keyboard_config.py
--- old/xpra-3.0.5/xpra/platform/win32/keyboard_config.py       2019-09-24 
15:54:00.000000000 +0200
+++ new/xpra-3.0.6/xpra/platform/win32/keyboard_config.py       2020-01-25 
11:03:51.000000000 +0100
@@ -36,9 +36,9 @@
         return "win32.KeyboardConfig"
 
 
-    def do_get_keycode(self, client_keycode, keyname, pressed, modifiers):
+    def do_get_keycode(self, client_keycode, keyname, pressed, modifiers, 
group):
         keycode = KEYCODES.get(keyname, -1)
-        log("get_keycode%s=%s", (client_keycode, keyname, pressed, modifiers), 
keycode)
+        log("get_keycode%s=%s", (client_keycode, keyname, pressed, modifiers, 
group), keycode)
         return keycode
 
     def make_keymask_match(self, modifier_list, ignored_modifier_keycode=None, 
ignored_modifier_keynames=None):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/platform/xposix/gui.py 
new/xpra-3.0.6/xpra/platform/xposix/gui.py
--- old/xpra-3.0.5/xpra/platform/xposix/gui.py  2020-01-01 15:09:30.000000000 
+0100
+++ new/xpra-3.0.6/xpra/platform/xposix/gui.py  2020-02-07 12:19:09.000000000 
+0100
@@ -208,12 +208,13 @@
         from xpra.x11.bindings.randr_bindings import RandRBindings  
#@UnresolvedImport
         with xlog:
             randr_bindings = RandRBindings()
-            wmm, hmm = randr_bindings.get_screen_size_mm()
-            w, h =  randr_bindings.get_screen_size()
-            dpix = iround(w * 25.4 / wmm)
-            dpiy = iround(h * 25.4 / hmm)
-            screenlog("xdpi=%s, ydpi=%s - size-mm=%ix%i, size=%ix%i", dpix, 
dpiy, wmm, hmm, w, h)
-            return dpix, dpiy
+            if randr_bindings.has_randr():
+                wmm, hmm = randr_bindings.get_screen_size_mm()
+                w, h =  randr_bindings.get_screen_size()
+                dpix = iround(w * 25.4 / wmm)
+                dpiy = iround(h * 25.4 / hmm)
+                screenlog("xdpi=%s, ydpi=%s - size-mm=%ix%i, size=%ix%i", 
dpix, dpiy, wmm, hmm, w, h)
+                return dpix, dpiy
     return -1, -1
 
 def get_xdpi():
@@ -370,7 +371,8 @@
         try:
             from xpra.x11.bindings.randr_bindings import RandRBindings      
#@UnresolvedImport
             randr = RandRBindings()
-            v = randr.get_vrefresh()
+            if randr.has_randr():
+                v = randr.get_vrefresh()
         except Exception as e:
             log("get_vrefresh()", exc_info=True)
             log.warn("Warning: failed to query the display vertical refresh 
rate:")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/scripts/config.py 
new/xpra-3.0.6/xpra/scripts/config.py
--- old/xpra-3.0.5/xpra/scripts/config.py       2019-11-08 16:44:54.000000000 
+0100
+++ new/xpra-3.0.6/xpra/scripts/config.py       2020-02-07 12:19:09.000000000 
+0100
@@ -814,7 +814,7 @@
     #we don't enable memfd on Ubuntu 16.04,
     #we just don't disable it (because the option does not exist!):
     from xpra.util import envbool
-    MEMFD = envbool("XPRA_PULSEAUDIO_MEMFD", is_Ubuntu() and 
getUbuntuVersion()<=(16, 4))
+    MEMFD = envbool("XPRA_PULSEAUDIO_MEMFD", False)
     if not MEMFD:
         cmd.append("--enable-memfd=no")
     return cmd
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/server/keyboard_config_base.py 
new/xpra-3.0.6/xpra/server/keyboard_config_base.py
--- old/xpra-3.0.5/xpra/server/keyboard_config_base.py  2019-09-24 
15:54:01.000000000 +0200
+++ new/xpra-3.0.6/xpra/server/keyboard_config_base.py  2020-01-25 
11:03:51.000000000 +0100
@@ -43,19 +43,21 @@
     def make_keymask_match(self, modifier_list, ignored_modifier_keycode=None, 
ignored_modifier_keynames=None):
         pass
 
-    def get_keycode(self, client_keycode, keyname, pressed, modifiers):
+    def get_keycode(self, client_keycode, keyname, pressed, modifiers, group):
+        if not keyname and client_keycode<0:
+            return -1
         if not pressed:
             keycode = self.pressed_translation.get(client_keycode)
             if keycode:
                 #del self.pressed_translation[client_keycode]
                 return keycode
-        keycode = self.do_get_keycode(client_keycode, keyname, pressed, 
modifiers)
+        keycode = self.do_get_keycode(client_keycode, keyname, pressed, 
modifiers, group)
         if pressed not in (None, -1):
             #keep track of it so we can unpress the same key:
             self.pressed_translation[client_keycode] = keycode
         return keycode
 
-    def do_get_keycode(self, _client_keycode, _keyname, _pressed, _modifiers):
+    def do_get_keycode(self, _client_keycode, _keyname, _pressed, _modifiers, 
_group):
         from xpra.log import Logger
         log = Logger("keyboard")
         log.warn("Warning: %s does not implement get_keycode!", type(self))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/server/mixins/input_server.py 
new/xpra-3.0.6/xpra/server/mixins/input_server.py
--- old/xpra-3.0.5/xpra/server/mixins/input_server.py   2019-09-24 
15:54:01.000000000 +0200
+++ new/xpra-3.0.6/xpra/server/mixins/input_server.py   2020-01-25 
11:03:51.000000000 +0100
@@ -156,8 +156,9 @@
         keyname = bytestostr(keyname)
         modifiers = tuple(bytestostr(x) for x in modifiers)
         self.set_ui_driver(ss)
-        self.set_keyboard_layout_group(group)
-        keycode = self.get_keycode(ss, client_keycode, keyname, pressed, 
modifiers)
+        if group>=0:
+            self.set_keyboard_layout_group(group)
+        keycode = self.get_keycode(ss, client_keycode, keyname, pressed, 
modifiers, group)
         keylog("process_key_action(%s) server keycode=%s", packet, keycode)
         #currently unused: (group, is_modifier) = packet[8:10]
         self._focus(ss, wid, None)
@@ -175,8 +176,8 @@
                 keylog.error(" for keyname=%s, keyval=%i, keycode=%i", 
keyname, keyval, keycode)
         ss.user_event()
 
-    def get_keycode(self, ss, client_keycode, keyname, pressed, modifiers):
-        return ss.get_keycode(client_keycode, keyname, pressed, modifiers)
+    def get_keycode(self, ss, client_keycode, keyname, pressed, modifiers, 
group):
+        return ss.get_keycode(client_keycode, keyname, pressed, modifiers, 
group)
 
     def fake_key(self, keycode, press):
         pass
@@ -247,13 +248,16 @@
     def _process_key_repeat(self, proto, packet):
         if self.readonly:
             return
-        wid, keyname, keyval, client_keycode, modifiers = packet[1:6]
         ss = self.get_server_source(proto)
         if ss is None:
             return
+        wid, keyname, keyval, client_keycode, modifiers = packet[1:6]
         keyname = bytestostr(keyname)
         modifiers = tuple(bytestostr(x) for x in modifiers)
-        keycode = ss.get_keycode(client_keycode, keyname, modifiers)
+        group = 0
+        if len(packet)>=7:
+            group = packet[6]
+        keycode = ss.get_keycode(client_keycode, keyname, modifiers, group)
         #key repeat uses modifiers from a pointer event, so ignore 
mod_pointermissing:
         ss.make_keymask_match(modifiers)
         if not ss.keyboard_config.sync:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/server/mixins/networkstate_server.py 
new/xpra-3.0.6/xpra/server/mixins/networkstate_server.py
--- old/xpra-3.0.5/xpra/server/mixins/networkstate_server.py    2019-09-24 
15:54:01.000000000 +0200
+++ new/xpra-3.0.6/xpra/server/mixins/networkstate_server.py    2020-02-07 
12:19:09.000000000 +0100
@@ -11,7 +11,7 @@
 from xpra.server.mixins.stub_server_mixin import StubServerMixin
 from xpra.scripts.config import parse_with_unit
 from xpra.simple_stats import std_unit
-from xpra.os_util import livefds, POSIX, PYTHON3, WIN32
+from xpra.os_util import livefds, POSIX, PYTHON3
 from xpra.util import envbool, envint, detect_leaks, typedict
 from xpra.log import Logger
 
@@ -23,7 +23,7 @@
 
 MIN_BANDWIDTH_LIMIT = envint("XPRA_MIN_BANDWIDTH_LIMIT", 1024*1024)
 MAX_BANDWIDTH_LIMIT = envint("XPRA_MAX_BANDWIDTH_LIMIT", 10*1024*1024*1024)
-
+CPUINFO = envbool("XPRA_CPUINFO", False)
 if PYTHON3:
     long = int
 
@@ -121,8 +121,7 @@
                 pass
 
     def init_cpuinfo(self):
-        if WIN32:
-            #crashes on win32!
+        if not CPUINFO:
             return
         #this crashes if not run from the UI thread!
         try:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/xpra-3.0.5/xpra/server/mixins/server_base_controlcommands.py 
new/xpra-3.0.6/xpra/server/mixins/server_base_controlcommands.py
--- old/xpra-3.0.5/xpra/server/mixins/server_base_controlcommands.py    
2019-09-24 15:54:01.000000000 +0200
+++ new/xpra-3.0.6/xpra/server/mixins/server_base_controlcommands.py    
2020-02-07 12:19:09.000000000 +0100
@@ -555,7 +555,8 @@
             elif press in ("0", "unpress"):
                 press = False
             else:
-                raise ControlError("if present, the press argument must be one 
of: %s", ("1", "press", "0", "unpress"))
+                raise ControlError("if present, the press argument must be one 
of: %s" %
+                                   csv(("1", "press", "0", "unpress")))
         self.fake_key(keycode, press)
 
     def control_command_sound_output(self, *args):
@@ -567,11 +568,11 @@
     def control_command_workspace(self, wid, workspace):
         window = self._id_to_window.get(wid)
         if not window:
-            raise ControlError("window %s does not exist", wid)
+            raise ControlError("window %s does not exist" % wid)
         if "workspace" not in window.get_property_names():
-            raise ControlError("cannot set workspace on window %s", window)
+            raise ControlError("cannot set workspace on window %s" % window)
         if workspace<0:
-            raise ControlError("invalid workspace value: %s", workspace)
+            raise ControlError("invalid workspace value: %s" % workspace)
         window.set_property("workspace", workspace)
         return "window %s moved to workspace %s" % (wid, workspace)
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/server/rfb/rfb_server.py 
new/xpra-3.0.6/xpra/server/rfb/rfb_server.py
--- old/xpra-3.0.5/xpra/server/rfb/rfb_server.py        2019-12-29 
17:24:22.000000000 +0100
+++ new/xpra-3.0.6/xpra/server/rfb/rfb_server.py        2020-01-25 
11:03:51.000000000 +0100
@@ -157,7 +157,7 @@
             return
         modifiers = []
         keyval = 0
-        keycode = source.keyboard_config.get_keycode(0, keyname, pressed, 
modifiers)
+        keycode = source.keyboard_config.get_keycode(0, keyname, pressed, 
modifiers, 0)
         log("rfb keycode(%s)=%s", keyname, keycode)
         if keycode:
             is_mod = source.keyboard_config.is_modifier(keycode)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/server/source/input_mixin.py 
new/xpra-3.0.6/xpra/server/source/input_mixin.py
--- old/xpra-3.0.5/xpra/server/source/input_mixin.py    2019-09-24 
15:54:01.000000000 +0200
+++ new/xpra-3.0.6/xpra/server/source/input_mixin.py    2020-01-25 
11:03:51.000000000 +0100
@@ -116,12 +116,12 @@
                 self.keyboard_config = current_keyboard_config
 
 
-    def get_keycode(self, client_keycode, keyname, pressed, modifiers):
+    def get_keycode(self, client_keycode, keyname, pressed, modifiers, group):
         kc = self.keyboard_config
         if kc is None:
             log.info("ignoring client key %s / %s since keyboard is not 
configured", client_keycode, keyname)
             return -1
-        return kc.get_keycode(client_keycode, keyname, pressed, modifiers)
+        return kc.get_keycode(client_keycode, keyname, pressed, modifiers, 
group)
 
 
     def update_mouse(self, wid, x, y, rx, ry):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/server/window/window_source.py 
new/xpra-3.0.6/xpra/server/window/window_source.py
--- old/xpra-3.0.5/xpra/server/window/window_source.py  2020-01-01 
15:09:30.000000000 +0100
+++ new/xpra-3.0.6/xpra/server/window/window_source.py  2020-02-07 
12:19:10.000000000 +0100
@@ -1208,7 +1208,7 @@
         cf = (100+cv*500)/100.0    #high congestion value -> very high delay
         #bandwidth limit is used to set a minimum on the delay
         min_delay = int(max(100*cf, self.auto_refresh_delay, 50 * sizef, 
self.batch_config.delay*4))
-        bwl = self.bandwidth_limit
+        bwl = self.bandwidth_limit or 0
         if bwl>0:
             #1Mbps -> 1s, 10Mbps -> 0.1s
             min_delay = max(min_delay, 1000*1000*1000//bwl)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/src_info.py 
new/xpra-3.0.6/xpra/src_info.py
--- old/xpra-3.0.5/xpra/src_info.py     2020-01-08 12:52:13.000000000 +0100
+++ new/xpra-3.0.6/xpra/src_info.py     2020-02-07 12:24:52.000000000 +0100
@@ -1,2 +1,2 @@
 LOCAL_MODIFICATIONS=0
-REVISION=24930
+REVISION=25177
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/version_util.py 
new/xpra-3.0.6/xpra/version_util.py
--- old/xpra-3.0.5/xpra/version_util.py 2019-11-08 16:44:54.000000000 +0100
+++ new/xpra-3.0.6/xpra/version_util.py 2020-02-07 12:19:10.000000000 +0100
@@ -38,7 +38,7 @@
     try:
         from xpra.src_info import REVISION, LOCAL_MODIFICATIONS
         s += "-r%s%s" % (REVISION, "M" if LOCAL_MODIFICATIONS>0 else "")
-    except ImportError:
+    except (ImportError, TypeError):
         pass
     return s
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/x11/gtk_x11/composite.py 
new/xpra-3.0.6/xpra/x11/gtk_x11/composite.py
--- old/xpra-3.0.5/xpra/x11/gtk_x11/composite.py        2019-09-24 
15:54:02.000000000 +0200
+++ new/xpra-3.0.6/xpra/x11/gtk_x11/composite.py        2020-02-07 
12:19:10.000000000 +0100
@@ -89,7 +89,11 @@
         listening = []
         e = None
         try:
-            root = self.client_window.get_screen().get_root_window()
+            screen = self.client_window.get_screen()
+            if not screen:
+                log("cannot set pixmap on client window - maybe deleted?")
+                return
+            root = screen.get_root_window()
             gdkworld = None
             world = get_world_window()
             if world:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/x11/gtk_x11/tray.py 
new/xpra-3.0.6/xpra/x11/gtk_x11/tray.py
--- old/xpra-3.0.5/xpra/x11/gtk_x11/tray.py     2019-09-24 15:54:02.000000000 
+0200
+++ new/xpra-3.0.6/xpra/x11/gtk_x11/tray.py     2020-02-07 12:19:10.000000000 
+0100
@@ -282,7 +282,10 @@
         X11Window.Reparent(xwin, xtray, 0, 0)
         X11Window.MapRaised(xwin)
         log("dock_tray(%#x) new tray container window %#x", xid, xtray)
-        tray_window.invalidate_rect(gdk.Rectangle(width=w, height=h), True)
+        rect = gdk.Rectangle()
+        rect.width = w
+        rect.height = h
+        tray_window.invalidate_rect(rect, True)
         X11Window.send_xembed_message(xwin, XEMBED_EMBEDDED_NOTIFY, 0, xtray, 
XEMBED_VERSION)
 
     def move_resize(self, window, x, y, w, h):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/x11/server.py 
new/xpra-3.0.6/xpra/x11/server.py
--- old/xpra-3.0.5/xpra/x11/server.py   2020-01-01 15:09:30.000000000 +0100
+++ new/xpra-3.0.6/xpra/x11/server.py   2020-01-25 11:03:51.000000000 +0100
@@ -828,8 +828,17 @@
         assert len(event.data)==5
         #x_root, y_root, direction, button, source_indication = event.data
         wid = self._window_to_id[window]
-        for ss in self._server_sources.values():
-            ss.initiate_moveresize(wid, window, *event.data)
+        #find clients that handle windows:
+        wsources = [ss for ss in self._server_sources.values() is 
isinstance(ss, WindowsMixin)]
+        if not wsources:
+            return
+        #prefer the "UI driver" if we find it:
+        driversources = [ss for ss in wsources if self.ui_driver==ss.uuid]
+        if driversources:
+            driversources[0].initiate_moveresize(wid, window, *event.data)
+            return
+        #otherwise, fallback to the first one:
+        wsources[0].initiate_moveresize(wid, window, *event.data)
 
 
     def _raised_window(self, window, event):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/x11/server_keyboard_config.py 
new/xpra-3.0.6/xpra/x11/server_keyboard_config.py
--- old/xpra-3.0.5/xpra/x11/server_keyboard_config.py   2019-09-24 
15:54:02.000000000 +0200
+++ new/xpra-3.0.6/xpra/x11/server_keyboard_config.py   2020-01-25 
11:03:51.000000000 +0100
@@ -411,10 +411,12 @@
             log("set_default_keymap: modifier_map=%s", self.modifier_map)
 
 
-    def do_get_keycode(self, client_keycode, keyname, pressed, modifiers):
+    def do_get_keycode(self, client_keycode, keyname, pressed, modifiers, 
group):
         if not self.enabled:
             log("ignoring keycode since keyboard is turned off")
             return -1
+        if keyname=="0xffffff":
+            return -1
         keycode = None
         if self.xkbmap_query:
             keycode = self.keycode_translation.get((client_keycode, keyname)) 
or client_keycode
@@ -422,7 +424,7 @@
         else:
             #non-native: try harder to find matching keysym
             #first, try to honour shift state:
-            shift = "shift" in modifiers
+            shift = ("shift" in modifiers) ^ ("lock" in modifiers)
             mode = 0
             for mod in modifiers:
                 names = self.keynames_for_mod.get(mod, [])
@@ -431,10 +433,23 @@
                         mode = 1
                         break
             level = int(shift) + int(mode)*2
-            keycode = self.keycode_translation.get((keyname, level))
+            levels = []
+            if group:
+                levels.append(level+4)
+            levels.append(level)
+            for i in range(4):
+                level = int(shift) + i*2
+                if level not in levels:
+                    levels.append(level)
+            for level in levels:
+                keycode = self.keycode_translation.get((keyname, level))
+                if keycode:
+                    log("get_keycode(%s, %s, %s, %s)=%i (level=%i, shift=%s, 
mode=%i)",
+                        client_keycode, keyname, modifiers, group, keycode, 
level, shift, mode)
+                    break
             if keycode is None:
-                keycode = self.keycode_translation.get(keyname, client_keycode)
-            log("get_keycode(%s, %s, %s)=%i (level=%i)", client_keycode, 
keyname, modifiers, keycode, level)
+                keycode = self.keycode_translation.get(keyname, -1)
+                log("get_keycode(%s, %s)=%i (keyname translation)", 
client_keycode, keyname, keycode)
         return keycode
 
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xpra-3.0.5/xpra/x11/x11_server_core.py 
new/xpra-3.0.6/xpra/x11/x11_server_core.py
--- old/xpra-3.0.5/xpra/x11/x11_server_core.py  2019-09-24 15:54:02.000000000 
+0200
+++ new/xpra-3.0.6/xpra/x11/x11_server_core.py  2020-02-07 12:19:10.000000000 
+0100
@@ -413,14 +413,15 @@
                 "XTest"                 : X11Keyboard.hasXTest(),
                 })
         #randr:
-        with xlog:
-            sizes = RandR.get_xrr_screen_sizes()
-            if self.randr and len(sizes)>=0:
-                sinfo["randr"] = {
-                    ""          : True,
-                    "options"   : tuple(reversed(sorted(sizes))),
-                    "exact"     : self.randr_exact_size,
-                    }
+        if self.randr:
+            with xlog:
+                sizes = RandR.get_xrr_screen_sizes()
+                if len(sizes)>=0:
+                    sinfo["randr"] = {
+                        ""          : True,
+                        "options"   : tuple(reversed(sorted(sizes))),
+                        "exact"     : self.randr_exact_size,
+                        }
         return info
 
 
@@ -495,7 +496,7 @@
             keylog("clearing keys pressed: %s", self.keys_pressed)
             with xsync:
                 for keycode in self.keys_pressed:
-                    X11Keyboard.xtest_fake_key(keycode, False)
+                    self.fake_key(keycode, False)
             self.keys_pressed = {}
         #this will take care of any remaining ones we are not aware of:
         #(there should not be any - but we want to be certain)
@@ -530,14 +531,15 @@
 
     def get_max_screen_size(self):
         max_w, max_h = self.root_window.get_geometry()[2:4]
-        sizes = RandR.get_xrr_screen_sizes()
-        if self.randr and len(sizes)>=1:
-            for w,h in sizes:
-                max_w = max(max_w, w)
-                max_h = max(max_h, h)
-        if max_w>MAX_WINDOW_SIZE or max_h>MAX_WINDOW_SIZE:
-            screenlog.warn("maximum size is very large: %sx%s, you may 
encounter window sizing problems", max_w, max_h)
-        screenlog("get_max_screen_size()=%s", (max_w, max_h))
+        if self.randr:
+            sizes = RandR.get_xrr_screen_sizes()
+            if self.randr and len(sizes)>=1:
+                for w,h in sizes:
+                    max_w = max(max_w, w)
+                    max_h = max(max_h, h)
+            if max_w>MAX_WINDOW_SIZE or max_h>MAX_WINDOW_SIZE:
+                screenlog.warn("maximum size is very large: %sx%s, you may 
encounter window sizing problems", max_w, max_h)
+            screenlog("get_max_screen_size()=%s", (max_w, max_h))
         return max_w, max_h
 
 
@@ -586,6 +588,8 @@
         return self.do_get_best_screen_size(desired_w, desired_h, bigger)
 
     def do_get_best_screen_size(self, desired_w, desired_h, bigger=True):
+        if not self.randr:
+            return desired_w, desired_h
         screen_sizes = RandR.get_xrr_screen_sizes()
         if (desired_w, desired_h) in screen_sizes:
             return desired_w, desired_h
@@ -798,6 +802,9 @@
 
     def fake_key(self, keycode, press):
         keylog("fake_key(%s, %s)", keycode, press)
+        mink, maxk = X11Keyboard.get_minmax_keycodes()
+        if keycode<mink or keycode>maxk:
+            return
         with xsync:
             X11Keyboard.xtest_fake_key(keycode, press)
 


++++++ xpra-paths.patch ++++++
--- /var/tmp/diff_new_pack.DwatAp/_old  2020-02-10 21:54:47.662236460 +0100
+++ /var/tmp/diff_new_pack.DwatAp/_new  2020-02-10 21:54:47.662236460 +0100
@@ -1,14 +1,14 @@
-Index: xpra-3.0.5/setup.py
+Index: xpra-3.0.6/setup.py
 ===================================================================
---- xpra-3.0.5.orig/setup.py
-+++ xpra-3.0.5/setup.py
+--- xpra-3.0.6.orig/setup.py
++++ xpra-3.0.6/setup.py
 @@ -1502,7 +1502,7 @@ else:
          add_data_files("%s/man1" % man_path,  ["man/xpra.1", 
"man/xpra_launcher.1"])
          add_data_files("share/applications",  glob.glob("xdg/*.desktop"))
          add_data_files("share/mime/packages", 
["xdg/application-x-xpraconfig.xml"])
 -        add_data_files("share/icons",         ["xdg/xpra.png", 
"xdg/xpra-mdns.png", "xdg/xpra-shadow.png"])
 +        add_data_files("share/pixmaps",         ["xdg/xpra.png", 
"xdg/xpra-mdns.png", "xdg/xpra-shadow.png"])
-         add_data_files("share/appdata",       ["xdg/xpra.appdata.xml"])
+         add_data_files("share/metainfo",      ["xdg/xpra.appdata.xml"])
  
      #here, we override build and install so we can
 @@ -1575,10 +1575,10 @@ else:


Reply via email to