[haiku-webkit-commits] r525 - webkit/trunk/WebKit/haiku/API

  • From: webkit@xxxxxxxxxxxxxxx
  • To: haiku-webkit-commits@xxxxxxxxxxxxx
  • Date: Mon, 14 Jun 2010 16:08:02 +0000

Author: stippi
Date: Mon Jun 14 16:08:02 2010
New Revision: 525
URL: http://mmlr.dyndns.org/changeset/525

Log:
Don't crash if the favicon bitmap at the index is NULL.

Modified:
   webkit/trunk/WebKit/haiku/API/WebSettings.cpp

Modified: webkit/trunk/WebKit/haiku/API/WebSettings.cpp
==============================================================================
--- webkit/trunk/WebKit/haiku/API/WebSettings.cpp       Mon Jun 14 16:02:50 
2010        (r524)
+++ webkit/trunk/WebKit/haiku/API/WebSettings.cpp       Mon Jun 14 16:08:02 
2010        (r525)
@@ -398,6 +398,8 @@
                size_t count = bitmapImage->frameCount();
                for (size_t i = 0; i < count; i++) {
                        bitmap = bitmapImage->frameAtIndex(i);
+                       if (!bitmap)
+                           continue;
                        if (bitmap->Bounds().IntegerWidth() + 1 == 
iconSize.width()
                                && bitmap->Bounds().IntegerHeight() + 1 == 
iconSize.height()) {
                                break;

Other related posts:

  • » [haiku-webkit-commits] r525 - webkit/trunk/WebKit/haiku/API - webkit