Index: bench/MathBench.cpp |
diff --git a/bench/MathBench.cpp b/bench/MathBench.cpp |
index 260159f3f0ebf58b513f1f16fb53e406130e9f1f..abe04e13d705cd97bb90bfe80a176fc34b0bbe79 100644 |
--- a/bench/MathBench.cpp |
+++ b/bench/MathBench.cpp |
@@ -514,15 +514,16 @@ private: |
template <typename T> |
class DivModBench : public SkBenchmark { |
- const char* fName; |
+ SkString fName; |
public: |
- explicit DivModBench(const char* name) : fName(name) { |
+ explicit DivModBench(const char* name) { |
+ fName.printf("divmod_%s", name); |
fIsRendering = false; |
} |
protected: |
virtual const char* onGetName() { |
- return SkStringPrintf("divmod_%s", fName).c_str(); |
+ return fName.c_str(); |
} |
virtual void onDraw(SkCanvas*) { |