Bug 640064 - crash [@ libc.so@0x1c25e] going to about:support crashes ideos s7; r=jmuizelaar
authorBenoit Jacob <bjacob@mozilla.com>
Wed, 09 Mar 2011 05:17:00 -0500
changeset 64628 243f2713f7f9bbb8c79508e01ceffc91306221e0
parent 64627 2bee01c51ed63f94ba8414d3f032b4e8b9816495
child 64629 c9115ff9e85a0958650dfbb125cd9f946e91c911
push idunknown
push userunknown
push dateunknown
reviewersjmuizelaar
bugs640064
milestone2.2a1pre
Bug 640064 - crash [@ libc.so@0x1c25e] going to about:support crashes ideos s7; r=jmuizelaar
gfx/thebes/GLContext.h
--- a/gfx/thebes/GLContext.h
+++ b/gfx/thebes/GLContext.h
@@ -2062,16 +2062,19 @@ public:
     nsTArray<NamedResource> mTrackedBuffers;
 #endif
 
 };
 
 inline PRBool
 DoesVendorStringMatch(const char* aVendorString, const char *aWantedVendor)
 {
+    if (!aVendorString || !aWantedVendor)
+        return PR_FALSE;
+
     const char *occurrence = strstr(aVendorString, aWantedVendor);
 
     // aWantedVendor not found
     if (!occurrence)
         return PR_FALSE;
 
     // aWantedVendor preceded by alpha character
     if (occurrence != aVendorString && isalpha(*(occurrence-1)))