nsCanvasRenderingContext2D_ContextState-allowonstack
author Benjamin Smedberg <benjamin@smedbergs.us>
Sat, 26 Jul 2008 22:49:39 -0400
changeset 167 a4da40849f5436e629c5732f4368c6c48189637f
parent 159 969d8d4050b8b7ebfb082c860b4a16df41348d52
permissions -rw-r--r--
State as of now

diff --git a/content/canvas/src/nsCanvasRenderingContext2D.cpp b/content/canvas/src/nsCanvasRenderingContext2D.cpp
--- a/content/canvas/src/nsCanvasRenderingContext2D.cpp
+++ b/content/canvas/src/nsCanvasRenderingContext2D.cpp
@@ -478,11 +478,11 @@ protected:
         TextBaseline textBaseline;
 
         nscolor colorStyles[STYLE_MAX];
-        nsCOMPtr<nsCanvasGradient> gradientStyles[STYLE_MAX];
-        nsCOMPtr<nsCanvasPattern> patternStyles[STYLE_MAX];
+        nsCanvasGradient* gradientStyles[STYLE_MAX];
+        nsCanvasPattern* patternStyles[STYLE_MAX];
     };
 
-    nsTArray<ContextState> mStyleStack;
+    nsTArray<ContextState, GCAllocator> mStyleStack;
 
     inline ContextState& CurrentState() {
         return mStyleStack[mSaveCount];