| Index: include/gpu/GrBuffer.h
 | 
| diff --git a/include/gpu/GrBuffer.h b/include/gpu/GrBuffer.h
 | 
| index 7e04577543f2922a816c7199081d740c676297a4..923453c24cd387637738077e19206cadb171a5ef 100644
 | 
| --- a/include/gpu/GrBuffer.h
 | 
| +++ b/include/gpu/GrBuffer.h
 | 
| @@ -110,15 +110,17 @@ public:
 | 
|  protected:
 | 
|      GrBuffer(GrGpu* gpu, size_t gpuMemorySize, GrBufferType intendedType,
 | 
|               GrAccessPattern accessPattern, bool cpuBacked)
 | 
| -        : INHERITED(gpu, kCached_LifeCycle),
 | 
| +        : INHERITED(gpu),
 | 
|            fMapPtr(nullptr),
 | 
|            fGpuMemorySize(gpuMemorySize), // TODO: Zero for cpu backed buffers?
 | 
|            fAccessPattern(accessPattern),
 | 
| -          fCPUBacked(cpuBacked) {
 | 
| +          fCPUBacked(cpuBacked),
 | 
| +          fIntendedType(intendedType) {
 | 
| +    }
 | 
| +
 | 
| +    void computeScratchKey(GrScratchKey* key) const override {
 | 
|          if (!fCPUBacked && SkIsPow2(fGpuMemorySize) && kDynamic_GrAccessPattern == fAccessPattern) {
 | 
| -            GrScratchKey key;
 | 
| -            ComputeScratchKeyForDynamicBuffer(fGpuMemorySize, intendedType, &key);
 | 
| -            this->setScratchKey(key);
 | 
| +            ComputeScratchKeyForDynamicBuffer(fGpuMemorySize, fIntendedType, key);
 | 
|          }
 | 
|      }
 | 
|  
 | 
| @@ -134,7 +136,7 @@ private:
 | 
|      size_t            fGpuMemorySize;
 | 
|      GrAccessPattern   fAccessPattern;
 | 
|      bool              fCPUBacked;
 | 
| -
 | 
| +    GrBufferType      fIntendedType;
 | 
|      typedef GrGpuResource INHERITED;
 | 
|  };
 | 
|  
 | 
| 
 |