Gitweb links:
...log
http://git.netsurf-browser.org/netsurf.git/shortlog/cfbd16cf7ea3335b7ac75989c4ffa63306224dfc
...commit
http://git.netsurf-browser.org/netsurf.git/commit/cfbd16cf7ea3335b7ac75989c4ffa63306224dfc
...tree
http://git.netsurf-browser.org/netsurf.git/tree/cfbd16cf7ea3335b7ac75989c4ffa63306224dfc
The branch, master has been updated
via cfbd16cf7ea3335b7ac75989c4ffa63306224dfc (commit)
from 231c96cf8d6d5deb051fedabdea5c6969f843e29 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=cfbd16cf7ea3335b7ac75989c4ffa63306224dfc
commit cfbd16cf7ea3335b7ac75989c4ffa63306224dfc
Author: Michael Drake <[email protected]>
Commit: Michael Drake <[email protected]>
Bitmap: Try to squash -Wtautological-constant-out-of-range-compare
diff --git a/desktop/bitmap.c b/desktop/bitmap.c
index b191043..acbd22e 100644
--- a/desktop/bitmap.c
+++ b/desktop/bitmap.c
@@ -106,7 +106,8 @@ static const char *bitmap__layout_to_str(enum bitmap_layout
layout)
[BITMAP_LAYOUT_ABGR8888] = "0xAABBGGRR (native endian)",
};
- if (layout >= (sizeof(str)) / sizeof(*str)) {
+ if ((size_t)layout >= (sizeof(str)) / sizeof(*str) ||
+ str[layout] == NULL) {
return "Unknown";
}
-----------------------------------------------------------------------
Summary of changes:
desktop/bitmap.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/desktop/bitmap.c b/desktop/bitmap.c
index b191043..acbd22e 100644
--- a/desktop/bitmap.c
+++ b/desktop/bitmap.c
@@ -106,7 +106,8 @@ static const char *bitmap__layout_to_str(enum bitmap_layout
layout)
[BITMAP_LAYOUT_ABGR8888] = "0xAABBGGRR (native endian)",
};
- if (layout >= (sizeof(str)) / sizeof(*str)) {
+ if ((size_t)layout >= (sizeof(str)) / sizeof(*str) ||
+ str[layout] == NULL) {
return "Unknown";
}
--
NetSurf Browser
_______________________________________________
netsurf-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]