Make not-reusing-scratch-textures only apply to texture uploads

https://codereview.chromium.org/53133002/



git-svn-id: http://skia.googlecode.com/svn/trunk@12037 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/src/gpu/GrSWMaskHelper.cpp b/src/gpu/GrSWMaskHelper.cpp
index 624b796..5fb944b 100644
--- a/src/gpu/GrSWMaskHelper.cpp
+++ b/src/gpu/GrSWMaskHelper.cpp
@@ -138,6 +138,9 @@
     // writing since no one else will be using 'texture'
     bool reuseScratch = fContext->getGpu()->caps()->reuseScratchTextures();
 
+    // Since we're uploading to it, 'texture' shouldn't have a render target.
+    SkASSERT(NULL == texture->asRenderTarget());
+
     texture->writePixels(0, 0, fBM.width(), fBM.height(),
                          kAlpha_8_GrPixelConfig,
                          fBM.getPixels(), fBM.rowBytes(),