From e7578e27ccb638ca59ad250bc7a8049b3aa25df4 Mon Sep 17 00:00:00 2001 From: Brendan Taylor Date: Sat, 2 Apr 2011 08:14:56 -0600 Subject: fix returning to default encoding ("set current_encoding =") --- src/callbacks.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/callbacks.c') diff --git a/src/callbacks.c b/src/callbacks.c index deda426..360b0c4 100644 --- a/src/callbacks.c +++ b/src/callbacks.c @@ -292,8 +292,11 @@ cmd_caret_browsing() { void set_current_encoding() { - webkit_web_view_set_custom_encoding(uzbl.gui.web_view, - uzbl.behave.current_encoding); + gchar *encoding = uzbl.behave.current_encoding; + if(strlen(encoding) == 0) + encoding = NULL; + + webkit_web_view_set_custom_encoding(uzbl.gui.web_view, encoding); } -- cgit v1.2.3