Title: [139988] trunk/Source/WebCore
Revision
139988
Author
commit-qu...@webkit.org
Date
2013-01-17 10:29:47 -0800 (Thu, 17 Jan 2013)

Log Message

[AC] Memory leak in GLXConfigSelector::createConfig()
https://bugs.webkit.org/show_bug.cgi?id=106657

Patch by Sudarsana Nagineni <sudarsana.nagin...@intel.com> on 2013-01-17
Reviewed by Laszlo Gombos.

Free the memory returned by glXGetVisualFromFBConfig() using
XFree to avoid a memory leak.

No new tests. No change in behavior.

* platform/graphics/surfaces/glx/GLXConfigSelector.h:
(WebCore::GLXConfigSelector::createConfig):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (139987 => 139988)


--- trunk/Source/WebCore/ChangeLog	2013-01-17 18:28:20 UTC (rev 139987)
+++ trunk/Source/WebCore/ChangeLog	2013-01-17 18:29:47 UTC (rev 139988)
@@ -1,3 +1,18 @@
+2013-01-17  Sudarsana Nagineni  <sudarsana.nagin...@intel.com>
+
+        [AC] Memory leak in GLXConfigSelector::createConfig()
+        https://bugs.webkit.org/show_bug.cgi?id=106657
+
+        Reviewed by Laszlo Gombos.
+
+        Free the memory returned by glXGetVisualFromFBConfig() using
+        XFree to avoid a memory leak.
+
+        No new tests. No change in behavior.
+
+        * platform/graphics/surfaces/glx/GLXConfigSelector.h:
+        (WebCore::GLXConfigSelector::createConfig):
+
 2013-01-17  Sheriff Bot  <webkit.review....@gmail.com>
 
         Unreviewed, rolling out r139929.

Modified: trunk/Source/WebCore/platform/graphics/surfaces/glx/GLXConfigSelector.h (139987 => 139988)


--- trunk/Source/WebCore/platform/graphics/surfaces/glx/GLXConfigSelector.h	2013-01-17 18:28:20 UTC (rev 139987)
+++ trunk/Source/WebCore/platform/graphics/surfaces/glx/GLXConfigSelector.h	2013-01-17 18:29:47 UTC (rev 139988)
@@ -121,6 +121,9 @@
         bool found = false;
 
         for (int i = 0; i < numAvailableConfigs; ++i) {
+            if (m_visualInfo)
+                XFree(m_visualInfo);
+
             m_visualInfo = glXGetVisualFromFBConfig(m_sharedDisplay, temp[i]);
             if (!m_visualInfo)
                 continue;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to