From d4d6bc5d7f337c7ef77ecc8c87e843897a082179 Mon Sep 17 00:00:00 2001 From: Matt Pharr Date: Wed, 30 Nov 2011 10:32:03 -0800 Subject: [PATCH] Fix crasher from malformed program --- decl.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/decl.cpp b/decl.cpp index 04d19c39..0c613739 100644 --- a/decl.cpp +++ b/decl.cpp @@ -527,6 +527,9 @@ GetStructTypesNamesPositions(const std::vector &sd, std::set seenNames; for (unsigned int i = 0; i < sd.size(); ++i) { const Type *type = sd[i]->type; + if (type == NULL) + continue; + // FIXME: making this fake little DeclSpecs here is really // disgusting DeclSpecs ds(type);