Gitweb links:
...log
http://git.netsurf-browser.org/netsurf.git/shortlog/a59646cbf84d1bb463c4b9526dacdf40075851c2
...commit
http://git.netsurf-browser.org/netsurf.git/commit/a59646cbf84d1bb463c4b9526dacdf40075851c2
...tree
http://git.netsurf-browser.org/netsurf.git/tree/a59646cbf84d1bb463c4b9526dacdf40075851c2
The branch, master has been updated
via a59646cbf84d1bb463c4b9526dacdf40075851c2 (commit)
via 3cceb8ff2b48a0ca0411109c1ad441064132fd6e (commit)
from 360997c265c10a47a5421c4c1e74ece5a4d46725 (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=a59646cbf84d1bb463c4b9526dacdf40075851c2
commit a59646cbf84d1bb463c4b9526dacdf40075851c2
Author: Michael Drake <[email protected]>
Commit: Michael Drake <[email protected]>
Hashmap: Check for failure of first malloc.
diff --git a/utils/hashmap.c b/utils/hashmap.c
index 814dc55..9cdc5a2 100644
--- a/utils/hashmap.c
+++ b/utils/hashmap.c
@@ -67,6 +67,9 @@ hashmap_t *
hashmap_create(hashmap_parameters_t *params)
{
hashmap_t *ret = malloc(sizeof(hashmap_t));
+ if (ret == NULL) {
+ return NULL;
+ }
ret->params = params;
ret->bucket_count = DEFAULT_HASHMAP_BUCKETS;
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=3cceb8ff2b48a0ca0411109c1ad441064132fd6e
commit 3cceb8ff2b48a0ca0411109c1ad441064132fd6e
Author: Michael Drake <[email protected]>
Commit: Michael Drake <[email protected]>
Test: libmalloc_fig.so needs "-ldl".
diff --git a/test/Makefile b/test/Makefile
index 34434c3..82ffee6 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -165,7 +165,7 @@ TESTLDFLAGS := -L$(TESTROOT) \
# malloc faliure injection generator
$(TESTROOT)/libmalloc_fig.so:test/malloc_fig.c
- $(CC) -shared -fPIC -I. -std=c99 $(TEST_WARNFLAGS) $^ -o $@
+ $(CC) -shared -fPIC -I. -std=c99 $(TEST_WARNFLAGS) $^ -ldl -o $@
# Source files for all tests being compiled
TESTSOURCES :=
-----------------------------------------------------------------------
Summary of changes:
test/Makefile | 2 +-
utils/hashmap.c | 3 +++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/test/Makefile b/test/Makefile
index 34434c3..82ffee6 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -165,7 +165,7 @@ TESTLDFLAGS := -L$(TESTROOT) \
# malloc faliure injection generator
$(TESTROOT)/libmalloc_fig.so:test/malloc_fig.c
- $(CC) -shared -fPIC -I. -std=c99 $(TEST_WARNFLAGS) $^ -o $@
+ $(CC) -shared -fPIC -I. -std=c99 $(TEST_WARNFLAGS) $^ -ldl -o $@
# Source files for all tests being compiled
TESTSOURCES :=
diff --git a/utils/hashmap.c b/utils/hashmap.c
index 814dc55..9cdc5a2 100644
--- a/utils/hashmap.c
+++ b/utils/hashmap.c
@@ -67,6 +67,9 @@ hashmap_t *
hashmap_create(hashmap_parameters_t *params)
{
hashmap_t *ret = malloc(sizeof(hashmap_t));
+ if (ret == NULL) {
+ return NULL;
+ }
ret->params = params;
ret->bucket_count = DEFAULT_HASHMAP_BUCKETS;
--
NetSurf Browser
_______________________________________________
netsurf-commits mailing list
[email protected]
http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org