Speculative render target ref/unref fixes

https://codereview.appspot.com/6592051/



git-svn-id: http://skia.googlecode.com/svn/trunk@5754 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/src/gpu/GrContext.cpp b/src/gpu/GrContext.cpp
index 7eb3422..560c1a7 100644
--- a/src/gpu/GrContext.cpp
+++ b/src/gpu/GrContext.cpp
@@ -1839,7 +1839,9 @@
                                    const SkRect& rect,
                                    float sigmaX, float sigmaY) {
     ASSERT_OWNED_RESOURCE(srcTexture);
-    GrRenderTarget* oldRenderTarget = this->getRenderTarget();
+
+    AutoRenderTarget art(this);
+
     AutoMatrix avm(this, GrMatrix::I());
     SkIRect clearRect;
     int scaleFactorX, radiusX;
@@ -1946,7 +1948,6 @@
         srcTexture = dstTexture;
         SkTSwap(dstTexture, tempTexture);
     }
-    this->setRenderTarget(oldRenderTarget);
     if (srcTexture == temp1.texture()) {
         return temp1.detach();
     } else if (srcTexture == temp2.texture()) {