-- Leo's gemini proxy

-- Connecting to git.thebackupbox.net:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini

repo: rxvt-unicode-sixel
action: commit
revision:
path_from:
revision_from: d310d058fadd16c9a0970411bb5bc9ef28219923:
path_to:
revision_to:

git.thebackupbox.net

rxvt-unicode-sixel

git://git.thebackupbox.net/rxvt-unicode-sixel

commit d310d058fadd16c9a0970411bb5bc9ef28219923
Author: Emanuele Giaquinta <emanuele.giaquinta@gmail.com>
Date:   Sun May 8 21:00:45 2011 +0000

    Fix pixmap leak.

diff --git a/src/background.C b/src/background.C

index e7b732fd1116779cdb2eb7696d87a32c04072fe7..

index ..c14ab37a5f0a038a656a06a07a2fa4fd556223a1 100644

--- a/src/background.C
+++ b/src/background.C
@@ -1279,40 +1279,40 @@ rxvt_term::make_transparency_pixmap ()
       bg_pmap_height = window_height;
     }

-  if (bg_pixmap == None)
-    return 0;
-
-  /* straightforward pixmap copy */
-  while (sx < 0) sx += (int)root_width;
-  while (sy < 0) sy += (int)root_height;
-
-  gcv.tile = recoded_root_pmap;
-  gcv.fill_style = FillTiled;
-  gcv.ts_x_origin = -sx;
-  gcv.ts_y_origin = -sy;
-  gc = XCreateGC (dpy, vt, GCFillStyle | GCTile | GCTileStipXOrigin | GCTileStipYOrigin, &gcv);
-
-  if (gc)
+  if (bg_pixmap != None)
     {
-      XFillRectangle (dpy, bg_pixmap, gc, 0, 0, window_width, window_height);
-      result |= BG_IS_VALID | (bg_flags & BG_EFFECTS_FLAGS);
-      XFreeGC (dpy, gc);
+      /* straightforward pixmap copy */
+      while (sx < 0) sx += (int)root_width;
+      while (sy < 0) sy += (int)root_height;

-      if (!(bg_flags & BG_CLIENT_RENDER))
+      gcv.tile = recoded_root_pmap;
+      gcv.fill_style = FillTiled;
+      gcv.ts_x_origin = -sx;
+      gcv.ts_y_origin = -sy;
+      gc = XCreateGC (dpy, vt, GCFillStyle | GCTile | GCTileStipXOrigin | GCTileStipYOrigin, &gcv);
+
+      if (gc)
         {
-          if ((bg_flags & BG_NEEDS_BLUR)
-              && (bg_flags & BG_HAS_RENDER_CONV))
-            {
-              if (blur_pixmap (bg_pixmap, visual, window_width, window_height))
-                result &= ~BG_NEEDS_BLUR;
-            }
-          if ((bg_flags & BG_NEEDS_TINT)
-              && (bg_flags & (BG_TINT_BITAND | BG_HAS_RENDER)))
+          XFillRectangle (dpy, bg_pixmap, gc, 0, 0, window_width, window_height);
+          result |= BG_IS_VALID | (bg_flags & BG_EFFECTS_FLAGS);
+          XFreeGC (dpy, gc);
+
+          if (!(bg_flags & BG_CLIENT_RENDER))
             {
-              if (tint_pixmap (bg_pixmap, visual, window_width, window_height))
-                result &= ~BG_NEEDS_TINT;
-            }
-        } /* server side rendering completed */
+              if ((bg_flags & BG_NEEDS_BLUR)
+                  && (bg_flags & BG_HAS_RENDER_CONV))
+                {
+                  if (blur_pixmap (bg_pixmap, visual, window_width, window_height))
+                    result &= ~BG_NEEDS_BLUR;
+                }
+              if ((bg_flags & BG_NEEDS_TINT)
+                  && (bg_flags & (BG_TINT_BITAND | BG_HAS_RENDER)))
+                {
+                  if (tint_pixmap (bg_pixmap, visual, window_width, window_height))
+                    result &= ~BG_NEEDS_TINT;
+                }
+            } /* server side rendering completed */
+        }
     }

   if (recoded_root_pmap != root_pixmap)

-----END OF PAGE-----

-- Response ended

-- Page fetched on Sun Jun 2 10:16:51 2024