Summary Files Commits Branches @commit @diff @stats
diff options
context:
space:
mode:
Commit5145eae758d3817c7bcc1a589514624bb62819e1 (patch)
Author
 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
2021-04-10 17:39:05 +0200
Committer
 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
2021-04-10 17:39:05 +0200
Files615e3ac93dba21dd30345e16f8b94dcfc837c9bd
goodwolf-5145eae758d3817c7bcc1a589514624bb62819e1.tar
goodwolf-5145eae758d3817c7bcc1a589514624bb62819e1.tar.gz
goodwolf-5145eae758d3817c7bcc1a589514624bb62819e1.zip
Parent231a7c45fac1d1811650ba9ae714de6975fc1da8 (diff)
assert webkit_download before using it
1 files changed, 3 insertions, 0 deletions
-rw-r--r--badwolf.c3
diff --git a/badwolf.c b/badwolf.c
index 84f4104..af2fe78 100644
--- a/badwolf.c
+++ b/badwolf.c
@@ -10,6 +10,7 @@
#include "keybindings.h"
#include "uri.h"
+#include <assert.h>
#include <glib/gi18n.h> /* _() and other internationalization/localization helpers */
#include <libsoup/soup.h> /* soup* */
#include <locale.h> /* LC_* */
@@ -466,6 +467,8 @@ web_contextCb_download_started(WebKitWebContext *web_context,
struct Client *browser = (struct Client *)user_data;
struct Download *download = malloc(sizeof(struct Download));
+ assert(webkit_download);
+
if(download != NULL)
{
download->window = browser->window;