diff options
author | Peter Hofmann <scm@uninformativ.de> | 2017-01-28 18:13:46 +0100 |
---|---|---|
committer | Peter Hofmann <scm@uninformativ.de> | 2017-01-28 18:13:46 +0100 |
commit | 364efc6f229f0fb5d743ed24a6617af4499347f8 (patch) | |
tree | d5ffde50ad1cd2b39c268b0ebb4e6a3de4a2dad5 | |
parent | 88b496e1537107361d9aba25b4c54176f13e8ecb (diff) | |
download | lariza-364efc6f229f0fb5d743ed24a6617af4499347f8.tar.gz |
s/malloc/calloc
-rw-r--r-- | browser.c | 7 |
1 files changed, 2 insertions, 5 deletions
@@ -125,16 +125,13 @@ client_new(const gchar *uri) return NULL; } - c = malloc(sizeof(struct Client)); + c = calloc(1, sizeof(struct Client)); if (!c) { - fprintf(stderr, __NAME__": fatal: malloc failed\n"); + fprintf(stderr, __NAME__": fatal: calloc failed\n"); exit(EXIT_FAILURE); } - c->external_handler_uri = NULL; - c->hover_uri = NULL; - c->win = NULL; if (embed != 0) { c->win = gtk_plug_new(embed); |