don't parse svgs we won't run

Change-Id: Ia3b11e5f785fb452a66067c0c063bc2354790978
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/340976
Reviewed-by: Florin Malita <fmalita@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
This commit is contained in:
Mike Klein 2020-12-04 09:20:32 -06:00 committed by Skia Commit-Bot
parent 7672470dff
commit 8ab65bf694

View File

@ -702,6 +702,9 @@ public:
} }
static sk_sp<SkPicture> ReadSVGPicture(const char* path) { static sk_sp<SkPicture> ReadSVGPicture(const char* path) {
if (CommandLineFlags::ShouldSkip(FLAGS_match, SkOSPath::Basename(path).c_str())) {
return nullptr;
}
sk_sp<SkData> data(SkData::MakeFromFileName(path)); sk_sp<SkData> data(SkData::MakeFromFileName(path));
if (!data) { if (!data) {
SkDebugf("Could not read %s.\n", path); SkDebugf("Could not read %s.\n", path);