commit 503a003584271840ade05c23a7c50d48d9c7fe01
parent 9710b9f35ca74c227fc6c6855349d9672497519f
Author: Michael Rasmussen <mir@datanom.net>
Date: Thu, 15 Nov 2018 23:06:29 +0100
Do not use G_LOG_LEVEL_ERROR. Makes claws crash
Signed-off-by: Michael Rasmussen <mir@datanom.net>
Diffstat:
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/plugins/litehtml_viewer/http.cpp b/src/plugins/litehtml_viewer/http.cpp
@@ -30,7 +30,7 @@ size_t http::curl_write_data(char* ptr, size_t size, size_t nmemb, void* data_pt
char *input = (char *) g_realloc(data->memory, data->size + realsize + 1);
if(input == NULL) {
/* out of memory! */
- g_log(NULL, G_LOG_LEVEL_ERROR, "not enough memory (realloc returned NULL)");
+ g_log(NULL, G_LOG_LEVEL_WARNING, "not enough memory (realloc returned NULL)");
return 0;
}
diff --git a/src/plugins/litehtml_viewer/lh_widget.cpp b/src/plugins/litehtml_viewer/lh_widget.cpp
@@ -150,14 +150,14 @@ GdkPixbuf *lh_widget::get_image(const litehtml::tchar_t* url, bool redraw_on_rea
g_log(NULL, G_LOG_LEVEL_MESSAGE, "Loading... %s", url);
- http http_loader;
- GInputStream *image = http_loader.load_url(url, &error);
+ http http_loader;
+ GInputStream *image = http_loader.load_url(url, &error);
if (!image) return NULL;
pixbuf = gdk_pixbuf_new_from_stream(image, NULL, &error);
if (error) {
- g_log(NULL, G_LOG_LEVEL_ERROR, "lh_widget::get_image: Could not create pixbuf %s", error->message);
+ g_log(NULL, G_LOG_LEVEL_WARNING, "lh_widget::get_image: Could not create pixbuf %s", error->message);
//g_object_unref(pixbuf);
pixbuf = NULL;
g_clear_error(&error);
@@ -403,7 +403,7 @@ static gboolean button_release_event(GtkWidget *widget, GdkEventButton *event,
w->m_clicked_url.c_str(),
GDK_CURRENT_TIME, &error);
if (error) {
- g_log(NULL, G_LOG_LEVEL_ERROR, "Failed opening url(%s): %s", w->m_clicked_url, error->message);
+ g_log(NULL, G_LOG_LEVEL_WARNING, "Failed opening url(%s): %s", w->m_clicked_url, error->message);
g_clear_error(&error);
}
}