[X2Go-Commits] [x2gokdrive] 01/01: improve icon handling in rootless mode.

git-admin at x2go.org git-admin at x2go.org
Fri Mar 4 16:34:35 CET 2022


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch master
in repository x2gokdrive.

commit 3bbfc9a7409e6fc090f577fa8de39e6809be098e
Author: Oleksandr Shneyder <o.shneyder at phoca-gmbh.de>
Date:   Fri Mar 4 09:34:19 2022 -0600

    improve icon handling in rootless mode.
---
 debian/changelog   | 1 +
 x2gokdriveremote.c | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index f563acc..42e09ef 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -30,6 +30,7 @@ x2gokdrive (0.0.0.1-0x2go1) UNRELEASED; urgency=medium
     - don't check cache data size, only amount of elements.
     - reduce amount of cache elements to save resources.
     - rootless mode for x2gokdrive.
+    - improve icon handling in rootless mode.
 
   [ Mihai Moldovan ]
   * Initial release:
diff --git a/x2gokdriveremote.c b/x2gokdriveremote.c
index e3e4441..bba6ec1 100644
--- a/x2gokdriveremote.c
+++ b/x2gokdriveremote.c
@@ -3995,11 +3995,14 @@ void remote_check_window(WindowPtr win)
             }
             if(prop->propertyName==MakeAtom("_NET_WM_ICON", strlen("_NET_WM_ICON"),FALSE) && prop->data)
             {
+//                 EPHYR_DBG("_NET_WM_ICON size: %d",prop->size);
                 i=0;
                 while(i<prop->size/4)
                 {
                     iw=((uint32_t*)prop->data)[i++];
                     ih=((uint32_t*)prop->data)[i++];
+                    if(!iw || !ih ||iw>256 ||  ih>256)
+                        break;
 //                     EPHYR_DBG("ICON: %dx%d", iw, ih);
                     if(iw>max_icon_w)
                     {

--
Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2gokdrive.git


More information about the x2go-commits mailing list