Skip to content

Commit

Permalink
load_icon can fail with an exception, apparently
Browse files Browse the repository at this point in the history
git-svn-id: https://xpra.org/svn/Xpra/trunk@18058 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Jan 19, 2018
1 parent 4e6b967 commit 440a635
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions src/xpra/x11/gtk2/models/window.py
Original file line number Diff line number Diff line change
Expand Up @@ -696,10 +696,13 @@ def get_default_window_icon(self):
iconlog("%s.lookup_icon(%s)=%s", it, icon_name, i)
if not i:
continue
p = i.load_icon()
iconlog("%s.load_icon()=%s", i, p)
if p:
break
try:
p = i.load_icon()
iconlog("%s.load_icon()=%s", i, p)
if p:
break
except Exception:
iconlog("%s.load_icon()", i, exc_info=True)
if p is None:
return None
#to make it consistent with the "icon" property,
Expand Down

0 comments on commit 440a635

Please sign in to comment.