summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorportix <none@none>2012-05-30 13:47:06 +0200
committerportix <none@none>2012-05-30 13:47:06 +0200
commit5de803da7bde5953b33fb13bf8f5bf7f0e81fc32 (patch)
tree3406fd0bdeabdfd3ad10ae439dfa5e460c4da97d /src
parent9e26c3232e00613a37a0671768ad6ad61e924f36 (diff)
downloaddwb-5de803da7bde5953b33fb13bf8f5bf7f0e81fc32.zip
Fix all -Wextra warnings except for -Wunused-parameter
Diffstat (limited to 'src')
-rw-r--r--src/adblock.c2
-rw-r--r--src/commands.c14
-rw-r--r--src/config.h592
-rw-r--r--src/download.c4
-rw-r--r--src/dwb.c18
-rw-r--r--src/dwb.h1
-rw-r--r--src/html.c2
-rw-r--r--src/plugins.c8
-rw-r--r--src/scripts.c2
-rw-r--r--src/session.c2
-rw-r--r--src/util.c2
11 files changed, 325 insertions, 322 deletions
diff --git a/src/adblock.c b/src/adblock.c
index 9eae2481..51bf61fa 100644
--- a/src/adblock.c
+++ b/src/adblock.c
@@ -182,7 +182,7 @@ adblock_match(GPtrArray *array, const char *uri, const char *uri_host, const cha
}
suburis[uc++] = NULL;
- for (int i=0; i<array->len; i++) {
+ for (guint i=0; i<array->len; i++) {
rule = g_ptr_array_index(array, i);
if ( (attributes & AA_DOCUMENT && !(rule->attributes & AA_DOCUMENT)) || (attributes & AA_SUBDOCUMENT && !(rule->attributes & AA_SUBDOCUMENT)) )
continue;
diff --git a/src/commands.c b/src/commands.c
index 2dc77813..41a61673 100644
--- a/src/commands.c
+++ b/src/commands.c
@@ -30,10 +30,12 @@
#include "download.h"
#include "js.h"
-static int inline dwb_floor(double x) {
+inline static int
+dwb_floor(double x) {
return x >= 0 ? (int) x : (int) x - 1;
}
-static int inline modulo(int x, int y) {
+inline static int
+modulo(int x, int y) {
return x - dwb_floor((double)x/y) * y;
}
/* commands.h {{{*/
@@ -73,14 +75,14 @@ commands_simple_command(KeyMap *km) {
}/*}}}*/
static WebKitWebView *
commands_get_webview_with_nummod() {
- if (dwb.state.nummod > 0 && dwb.state.nummod <= g_list_length(dwb.state.views))
+ if (dwb.state.nummod > 0 && dwb.state.nummod <= (gint)g_list_length(dwb.state.views))
return WEBVIEW(g_list_nth(dwb.state.views, NUMMOD - 1));
else
return CURRENT_WEBVIEW();
}
static GList *
commands_get_view_with_nummod() {
- if (dwb.state.nummod > 0 && dwb.state.nummod <= g_list_length(dwb.state.views))
+ if (dwb.state.nummod > 0 && dwb.state.nummod <= (gint)g_list_length(dwb.state.views))
return g_list_nth(dwb.state.views, NUMMOD - 1);
return dwb.state.fview;
}
@@ -239,7 +241,7 @@ commands_quickmark(KeyMap *km, Arg *arg) {
/* commands_reload(KeyMap *km, Arg *){{{*/
DwbStatus
commands_reload(KeyMap *km, Arg *arg) {
- GList *gl = dwb.state.nummod > 0 && dwb.state.nummod <= g_list_length(dwb.state.views)
+ GList *gl = dwb.state.nummod > 0 && dwb.state.nummod <= (gint)g_list_length(dwb.state.views)
? g_list_nth(dwb.state.views, dwb.state.nummod-1)
: dwb.state.fview;
dwb_reload(gl);
@@ -836,7 +838,7 @@ commands_dump(KeyMap *km, Arg *arg) {
DwbStatus
commands_sanitize(KeyMap *km, Arg *arg) {
Sanitize s = util_string_to_sanitize(arg->p);
- if (s == -1) {
+ if (s == SANITIZE_ERROR) {
return STATUS_ERROR;
}
if (s & SANITIZE_HISTORY) {
diff --git a/src/config.h b/src/config.h
index 600dcaf5..f9464eef 100644
--- a/src/config.h
+++ b/src/config.h
@@ -17,170 +17,170 @@
*/
static KeyValue KEYS[] = {
- { "tab_new", { "ga", 0, }, },
- { "allow_cookie", { "CC", 0, }, },
- { "allow_session_cookie", { "CS", 0, }, },
- { "allow_session_cookie_tmp", { "CT", 0, }, },
- { "bookmark", { "M", 0, }, },
- { "bookmarks", { "gb", 0, }, },
- { "tab_bookmarks", { "gB", 0, }, },
- { "win_bookmarks", { "wB", 0, }, },
- { "command_mode", { ":", 0, }, },
- { "only", { "co", 0, }, },
- { "find_forward", { "/", 0, }, },
- { "find_forward_ic", { "c/", 0, }, },
- { "find_next", { "n", 0, }, },
- { "find_previous", { "N", 0, }, },
- { "find_backward", { "?", 0, }, },
- { "find_backward_ic", { "c?", 0, }, },
- { "focus_next", { "J", 0, }, },
- { "focus_prev", { "K", 0, }, },
- { "focus_tab", { "T", 0, }, },
- { "hints", { "f", 0, }, },
- { "hints_links", { ";;", 0, }, },
- { "hints_images", { ";i", 0, }, },
- { "hints_images_tab", { ";I", 0, }, },
- { "hints_images_background", { ".i", 0, }, },
- { "hints_editable", { ";e", 0, }, },
- { "hints_url", { ";o", 0, }, },
- { "hints_url_tab", { ";O", 0, }, },
- { "hints_url_background", { ".o", 0, }, },
- { "hints_download", { ";d", 0 }, },
- { "hints_tab", { "F", 0, }, },
- { "hints_background", { ";b", 0, }, },
- { "hints_win", { "wf", 0, }, },
- { "hints_clipboard", { ";y", 0, }, },
- { "hints_primary", { ";Y", 0, }, },
- { "hints_rapid", { ";r", 0, }, },
- { "hints_rapid_win", { ";R", 0, }, },
- { "history_back", { "H", 0, }, },
- { "history_forward", { "L", 0, }, },
- { "tab_hist_back", { "th", 0, }, },
- { "tab_hist_forward", { "tl", 0, }, },
- { "win_hist_back", { "wh", 0, }, },
- { "win_hist_forward", { "wl", 0, }, },
- { "insert_mode", { "i", 0, }, },
- { "normal_mode", { "n", GDK_CONTROL_MASK, }, },
- { "open", { "o", 0, }, },
- { "open_url", { "go", 0, }, },
- { "tabopen", { "O", 0, }, },
- { "tabopen_url", { "gO", 0, }, },
- { "backopen", { "xo", 0, }, },
- { "backopen_url", { "xO", 0, }, },
- { "winopen", { "wo", 0, }, },
- { "winopen_url", { "wO", 0, }, },
- { "start_page", { "h", GDK_CONTROL_MASK, }, },
- { "quickmark", { "b", 0, }, },
- { "tab_quickmark", { "B", 0, }, },
- { "win_quickmark", { "wb", 0, }, },
- { "reload", { "r", 0, }, },
- { "reload_bypass_cache", { "R", 0, }, },
- { "close_tab", { "d", 0, }, },
- { "save_quickmark", { "m", 0, }, },
- { "scroll_bottom", { "G", 0, }, },
- { "scroll_down", { "j", 0, }, },
- { "scroll_left", { "h", 0, }, },
- { "scroll_halfpage_down", { "d", GDK_CONTROL_MASK, }, },
- { "scroll_halfpage_up", { "u", GDK_CONTROL_MASK, }, },
- { "scroll_page_down", { "f", GDK_CONTROL_MASK, }, },
- { "scroll_page_up", { "b", GDK_CONTROL_MASK, }, },
- { "scroll_right", { "l", 0, }, },
- { "scroll_top", { "gg", 0, }, },
- { "scroll_up", { "k", 0, }, },
- { "show_keys", { "Sk", 0, }, },
- { "show_settings", { "Ss", 0, }, },
- { "show_bookmarks", { "Sb", 0, }, },
- { "show_history", { "Sh", 0, }, },
- { "show_downloads", { "Sd", 0, }, },
- { "show_quickmarks", { "Sq", 0, }, },
- { "stop_loading", { "s", GDK_CONTROL_MASK, }, },
- { "view_source", { "gf", 0, }, },
- { "zoom_in", { "+", 0, }, },
- { "zoom", { "=", 0, }, },
- { "zoom_out", { "-", 0, }, },
- { "save_search_field", { "gs", 0, }, },
- { "reload_userscripts", { NULL, 0, }, },
- { "proxy", { "p" , GDK_CONTROL_MASK, }, },
- { "focus_input", { "gi", 0, }, },
- { "set_setting", { "ss", 0, }, },
- { "set_local_setting", { "sl", 0, }, },
- { "set_key", { "sk", 0, }, },
- { "yank", { "yy", 0, }, },
- { "yank_primary", { "yY", 0, }, },
- { "yank_title", { "yt", 0, }, },
- { "yank_title_primary", { "yT", 0, }, },
- { "paste", { "pp", 0, }, },
- { "paste_primary", { "pP", 0, }, },
- { "tab_paste", { "Pp", 0, }, },
- { "tab_paste_primary", { "PP", 0, }, },
- { "win_paste", { "wp", 0, }, },
- { "win_paste_primary", { "wP", 0, }, },
+ { "tab_new", { "ga", 0, 0 }, },
+ { "allow_cookie", { "CC", 0, 0 }, },
+ { "allow_session_cookie", { "CS", 0, 0 }, },
+ { "allow_session_cookie_tmp", { "CT", 0, 0 }, },
+ { "bookmark", { "M", 0, 0 }, },
+ { "bookmarks", { "gb", 0, 0 }, },
+ { "tab_bookmarks", { "gB", 0, 0 }, },
+ { "win_bookmarks", { "wB", 0, 0 }, },
+ { "command_mode", { ":", 0, 0 }, },
+ { "only", { "co", 0, 0 }, },
+ { "find_forward", { "/", 0, 0 }, },
+ { "find_forward_ic", { "c/", 0, 0 }, },
+ { "find_next", { "n", 0, 0 }, },
+ { "find_previous", { "N", 0, 0 }, },
+ { "find_backward", { "?", 0, 0 }, },
+ { "find_backward_ic", { "c?", 0, 0 }, },
+ { "focus_next", { "J", 0, 0 }, },
+ { "focus_prev", { "K", 0, 0 }, },
+ { "focus_tab", { "T", 0, 0 }, },
+ { "hints", { "f", 0, 0 }, },
+ { "hints_links", { ";;", 0, 0 }, },
+ { "hints_images", { ";i", 0, 0 }, },
+ { "hints_images_tab", { ";I", 0, 0 }, },
+ { "hints_images_background", { ".i", 0, 0 }, },
+ { "hints_editable", { ";e", 0, 0 }, },
+ { "hints_url", { ";o", 0, 0 }, },
+ { "hints_url_tab", { ";O", 0, 0 }, },
+ { "hints_url_background", { ".o", 0, 0 }, },
+ { "hints_download", { ";d", 0, 0 }, },
+ { "hints_tab", { "F", 0, 0 }, },
+ { "hints_background", { ";b", 0, 0 }, },
+ { "hints_win", { "wf", 0, 0 }, },
+ { "hints_clipboard", { ";y", 0, 0 }, },
+ { "hints_primary", { ";Y", 0, 0 }, },
+ { "hints_rapid", { ";r", 0, 0 }, },
+ { "hints_rapid_win", { ";R", 0, 0 }, },
+ { "history_back", { "H", 0, 0 }, },
+ { "history_forward", { "L", 0, 0 }, },
+ { "tab_hist_back", { "th", 0, 0 }, },
+ { "tab_hist_forward", { "tl", 0, 0 }, },
+ { "win_hist_back", { "wh", 0, 0 }, },
+ { "win_hist_forward", { "wl", 0, 0 }, },
+ { "insert_mode", { "i", 0, 0 }, },
+ { "normal_mode", { "n", GDK_CONTROL_MASK, 0 }, },
+ { "open", { "o", 0, 0 }, },
+ { "open_url", { "go", 0, 0 }, },
+ { "tabopen", { "O", 0, 0 }, },
+ { "tabopen_url", { "gO", 0, 0 }, },
+ { "backopen", { "xo", 0, 0 }, },
+ { "backopen_url", { "xO", 0, 0 }, },
+ { "winopen", { "wo", 0, 0 }, },
+ { "winopen_url", { "wO", 0, 0 }, },
+ { "start_page", { "h", GDK_CONTROL_MASK, 0 }, },
+ { "quickmark", { "b", 0, 0 }, },
+ { "tab_quickmark", { "B", 0, 0 }, },
+ { "win_quickmark", { "wb", 0, 0 }, },
+ { "reload", { "r", 0, 0 }, },
+ { "reload_bypass_cache", { "R", 0, 0 }, },
+ { "close_tab", { "d", 0, 0 }, },
+ { "save_quickmark", { "m", 0, 0 }, },
+ { "scroll_bottom", { "G", 0, 0 }, },
+ { "scroll_down", { "j", 0, 0 }, },
+ { "scroll_left", { "h", 0, 0 }, },
+ { "scroll_halfpage_down", { "d", GDK_CONTROL_MASK, 0 }, },
+ { "scroll_halfpage_up", { "u", GDK_CONTROL_MASK, 0 }, },
+ { "scroll_page_down", { "f", GDK_CONTROL_MASK, 0 }, },
+ { "scroll_page_up", { "b", GDK_CONTROL_MASK, 0 }, },
+ { "scroll_right", { "l", 0, 0 }, },
+ { "scroll_top", { "gg", 0, 0 }, },
+ { "scroll_up", { "k", 0, 0 }, },
+ { "show_keys", { "Sk", 0, 0 }, },
+ { "show_settings", { "Ss", 0, 0 }, },
+ { "show_bookmarks", { "Sb", 0, 0 }, },
+ { "show_history", { "Sh", 0, 0 }, },
+ { "show_downloads", { "Sd", 0, 0 }, },
+ { "show_quickmarks", { "Sq", 0, 0 }, },
+ { "stop_loading", { "s", GDK_CONTROL_MASK, 0 }, },
+ { "view_source", { "gf", 0, 0 }, },
+ { "zoom_in", { "+", 0, 0 }, },
+ { "zoom", { "=", 0, 0 }, },
+ { "zoom_out", { "-", 0, 0 }, },
+ { "save_search_field", { "gs", 0, 0 }, },
+ { "reload_userscripts", { NULL, 0, 0 }, },
+ { "proxy", { "p" , GDK_CONTROL_MASK, 0 }, },
+ { "focus_input", { "gi", 0, 0 }, },
+ { "set_setting", { "ss", 0, 0 }, },
+ { "set_local_setting", { "sl", 0, 0 }, },
+ { "set_key", { "sk", 0, 0 }, },
+ { "yank", { "yy", 0, 0 }, },
+ { "yank_primary", { "yY", 0, 0 }, },
+ { "yank_title", { "yt", 0, 0 }, },
+ { "yank_title_primary", { "yT", 0, 0 }, },
+ { "paste", { "pp", 0, 0 }, },
+ { "paste_primary", { "pP", 0, 0 }, },
+ { "tab_paste", { "Pp", 0, 0 }, },
+ { "tab_paste_primary", { "PP", 0, 0 }, },
+ { "win_paste", { "wp", 0, 0 }, },
+ { "win_paste_primary", { "wP", 0, 0 }, },
/* entry shortcuts */
- { "entry_delete_word", { "w", GDK_CONTROL_MASK, }, },
- { "entry_delete_word_forward",{ "e", GDK_CONTROL_MASK, }, },
- { "entry_delete_letter", { "h", GDK_CONTROL_MASK, }, },
- { "entry_delete_line", { "u", GDK_CONTROL_MASK, }, },
- { "entry_delete_line_end", { "e", GDK_CONTROL_MASK, }, },
- { "entry_word_forward", { "f", GDK_CONTROL_MASK, }, },
- { "entry_word_back", { "b", GDK_CONTROL_MASK, }, },
- { "entry_history_forward", { "j", GDK_CONTROL_MASK, }, },
- { "entry_history_back", { "k", GDK_CONTROL_MASK, }, },
- { "entry_escape", { "c", GDK_CONTROL_MASK, }, },
- { "entry_confirm", { "g", GDK_CONTROL_MASK, }, },
- { "download_set_execute", { "x", GDK_CONTROL_MASK, }, },
- { "complete_history", { "H", GDK_CONTROL_MASK, }, },
- { "complete_bookmarks", { "B", GDK_CONTROL_MASK, }, },
- { "complete_searchengines", { "S", GDK_CONTROL_MASK, }, },
- { "complete_userscript", { "U", GDK_CONTROL_MASK, }, },
- { "buffers", { "gt", 0 } },
+ { "entry_delete_word", { "w", GDK_CONTROL_MASK, 0 }, },
+ { "entry_delete_word_forward",{ "e", GDK_CONTROL_MASK, 0 }, },
+ { "entry_delete_letter", { "h", GDK_CONTROL_MASK, 0 }, },
+ { "entry_delete_line", { "u", GDK_CONTROL_MASK, 0 }, },
+ { "entry_delete_line_end", { "e", GDK_CONTROL_MASK, 0 }, },
+ { "entry_word_forward", { "f", GDK_CONTROL_MASK, 0 }, },
+ { "entry_word_back", { "b", GDK_CONTROL_MASK, 0 }, },
+ { "entry_history_forward", { "j", GDK_CONTROL_MASK, 0 }, },
+ { "entry_history_back", { "k", GDK_CONTROL_MASK, 0 }, },
+ { "entry_escape", { "c", GDK_CONTROL_MASK, 0 }, },
+ { "entry_confirm", { "g", GDK_CONTROL_MASK, 0 }, },
+ { "download_set_execute", { "x", GDK_CONTROL_MASK, 0 }, },
+ { "complete_history", { "H", GDK_CONTROL_MASK, 0 }, },
+ { "complete_bookmarks", { "B", GDK_CONTROL_MASK, 0 }, },
+ { "complete_searchengines", { "S", GDK_CONTROL_MASK, 0 }, },
+ { "complete_userscript", { "U", GDK_CONTROL_MASK, 0 }, },
+ { "buffers", { "gt", 0, 0 }, },
- { "web_inspector", { "wi", 0, }, },
+ { "web_inspector", { "wi", 0, 0 }, },
- { "save_session", { "ZZ", 0 }, },
- { "save_named_session", { "gZZ", 0 }, },
- { "toggle_scripts_uri", { "tsu", 0 }, },
- { "toggle_scripts_host", { "tsh", 0 }, },
- { "toggle_scripts_uri_tmp", { "ttu", 0 }, },
- { "toggle_scripts_host_tmp", { "tth", 0 }, },
- { "toggle_plugins_uri", { "pu", 0 }, },
- { "toggle_plugins_host", { "ph", 0 }, },
- { "toggle_plugins_uri_tmp", { "ptu", 0 }, },
- { "toggle_plugins_host_tmp", { "pth", 0 }, },
- { "new_tab", { "V", 0 }, },
- { "new_win", { "W", 0 }, },
- { "save", { "sf", 0 }, },
- { "undo", { "u", 0 }, },
- { "execute_userscript", { "eu", 0 }, },
- { "print", { "p", GDK_CONTROL_MASK | GDK_MOD1_MASK }, },
- { "load_html", { NULL, 0 }, },
- { "load_html_tab", { NULL, 0 }, },
- { "toggle_hidden_files", { "g.", 0 }, },
- { "complete_path", { "p", GDK_CONTROL_MASK }, },
- { "quit", { "q", GDK_CONTROL_MASK }, },
- { "fullscreen", { "@F11@", 0 }, },
- { "pass_through", { "i", GDK_CONTROL_MASK }, },
- { "open_editor", { "e", GDK_CONTROL_MASK }, },
- { "toggle_bars", { "xx", 0 }, },
- { "toggle_tabbar", { "xt", 0 }, },
- { "toggle_statusbar", { "xb", 0 }, },
- { "presentation_mode", { "@F12@", 0 }, },
- { "protect", { "P", GDK_CONTROL_MASK }, },
- { "lock_uri", { "xu", 0 }, },
- { "lock_domain", { "xd", 0 }, },
- { "back_new_tab", { "xb", 0 }, },
- { "visible", { "xv", 0 }, },
- { "execute_javascript", { NULL, 0 }, },
- { "set", { NULL, 0 }, },
- { "toggle_setting", { NULL, 0 }, },
- { "toggle_local_setting", { NULL, 0 }, },
- { "tab_move", { "gm", 0 }, },
- { "tab_move_left", { "gl", 0 }, },
- { "tab_move_right", { "gr", 0 }, },
- { "clear_tab", { "gc", 0 }, },
- { "cancel_download", { "ad", 0 }, },
- { "local_set", { NULL, 0 }, },
- { "dump", { NULL, 0 }, },
- { "sanitize", { NULL, 0 }, },
+ { "save_session", { "ZZ", 0, 0 }, },
+ { "save_named_session", { "gZZ", 0, 0 }, },
+ { "toggle_scripts_uri", { "tsu", 0, 0 }, },
+ { "toggle_scripts_host", { "tsh", 0, 0 }, },
+ { "toggle_scripts_uri_tmp", { "ttu", 0, 0 }, },
+ { "toggle_scripts_host_tmp", { "tth", 0, 0 }, },
+ { "toggle_plugins_uri", { "pu", 0, 0 }, },
+ { "toggle_plugins_host", { "ph", 0, 0 }, },
+ { "toggle_plugins_uri_tmp", { "ptu", 0, 0 }, },
+ { "toggle_plugins_host_tmp", { "pth", 0, 0 }, },
+ { "new_tab", { "V", 0, 0 }, },
+ { "new_win", { "W", 0, 0 }, },
+ { "save", { "sf", 0, 0 }, },
+ { "undo", { "u", 0, 0 }, },
+ { "execute_userscript", { "eu", 0, 0 }, },
+ { "print", { "p", GDK_CONTROL_MASK | GDK_MOD1_MASK, 0 }, },
+ { "load_html", { NULL, 0, 0 }, },
+ { "load_html_tab", { NULL, 0, 0 }, },
+ { "toggle_hidden_files", { "g.", 0, 0 }, },
+ { "complete_path", { "p", GDK_CONTROL_MASK, 0 }, },
+ { "quit", { "q", GDK_CONTROL_MASK, 0 }, },
+ { "fullscreen", { "@F11@", 0, 0 }, },
+ { "pass_through", { "i", GDK_CONTROL_MASK, 0 }, },
+ { "open_editor", { "e", GDK_CONTROL_MASK, 0 }, },
+ { "toggle_bars", { "xx", 0, 0 }, },
+ { "toggle_tabbar", { "xt", 0, 0 }, },
+ { "toggle_statusbar", { "xb", 0, 0 }, },
+ { "presentation_mode", { "@F12@", 0, 0 }, },
+ { "protect", { "P", GDK_CONTROL_MASK, 0 }, },
+ { "lock_uri", { "xu", 0, 0 }, },
+ { "lock_domain", { "xd", 0, 0 }, },
+ { "back_new_tab", { "xb", 0, 0 }, },
+ { "visible", { "xv", 0, 0 }, },
+ { "execute_javascript", { NULL, 0, 0 }, },
+ { "set", { NULL, 0, 0 }, },
+ { "toggle_setting", { NULL, 0, 0 }, },
+ { "toggle_local_setting", { NULL, 0, 0 }, },
+ { "tab_move", { "gm", 0, 0 }, },
+ { "tab_move_left", { "gl", 0, 0 }, },
+ { "tab_move_right", { "gr", 0, 0 }, },
+ { "clear_tab", { "gc", 0, 0 }, },
+ { "cancel_download", { "ad", 0, 0 }, },
+ { "local_set", { NULL, 0, 0 }, },
+ { "dump", { NULL, 0, 0 }, },
+ { "sanitize", { NULL, 0, 0 }, },
};
/* FUNCTION_MAP{{{*/
@@ -832,290 +832,290 @@ static FunctionMap FMAP [] = {
/* { name, description, builtin, global, type, argument, set-function */
static WebSettings DWB_SETTINGS[] = {
{ { "auto-load-images", "Load images automatically", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "auto-resize-window", "Autoresize window", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "auto-shrink-images", "Automatically shrink standalone images to fit", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "cursive-font-family", "Cursive font family used to display text", },
- SETTING_BUILTIN, CHAR, { .p = "serif" }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = "serif" }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "default-encoding", "Default encoding used to display text", },
- SETTING_BUILTIN, CHAR, { .p = NULL }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = NULL }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "default-font-family", "Default font family used to display text", },
- SETTING_BUILTIN, CHAR, { .p = "sans-serif" }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = "sans-serif" }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "default-font-size", "Default font size used to display text", },
- SETTING_BUILTIN, INTEGER, { .i = 12 }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, INTEGER, { .i = 12 }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "default-monospace-font-size", "Default monospace font size used to display text", },
- SETTING_BUILTIN, INTEGER, { .i = 10 }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, INTEGER, { .i = 10 }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-caret-browsing", "Whether to enable caret browsing", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-default-context-menu", "Whether to enable the right click context menu", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-developer-extras", "Whether developer extensions should be enabled", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-dns-prefetching", "Whether webkit prefetches domain names", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-dom-paste", "Whether to enable DOM paste", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-frame-flattening", "Whether to enable Frame Flattening", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-file-access-from-file-uris", "Whether file access from file uris is allowed", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-html5-database", "Enable HTML5 client side SQL-database support" },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-html5-local-storage", "Enable HTML5 local storage", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-java-applet", "Whether to enable java applets", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-offline-web-application-cache", "Enable HTML5 offline web application cache", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-page-cache", "Whether to enable page cache", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-plugins", "Whether to enable plugins", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-private-browsing", "Whether to enable private browsing mode", },
- SETTING_BUILTIN | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func) dwb_set_private_browsing, },
+ SETTING_BUILTIN | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func) dwb_set_private_browsing, { 0 }, },
{ { "enable-scripts", "Enable embedded scripting languages", },
- SETTING_PER_VIEW, BOOLEAN, { .b = true }, (S_Func) dwb_set_scripts, },
+ SETTING_PER_VIEW, BOOLEAN, { .b = true }, (S_Func) dwb_set_scripts, { 0 }, },
{ { "enable-site-specific-quirks", "Enable site-specific compatibility workarounds", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-spatial-navigation", "Spatial navigation", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-spell-checking", "Whether to enable spell checking", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-universal-access-from-file-uris", "Whether to allow files loaded through file:", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enable-xss-auditor", "Whether to enable the XSS auditor", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "enforce-96-dpi", "Enforce a resolution of 96 dpi", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "fantasy-font-family", "Default fantasy font family used to display text", },
- SETTING_BUILTIN, CHAR, { .p = "serif" }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = "serif" }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "javascript-can-access-clipboard", "Whether javascript can access clipboard", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "javascript-can-open-windows-automatically", "Whether javascript can open windows", },
- SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = false }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "minimum-font-size", "Minimum font size to display text", },
- SETTING_BUILTIN, INTEGER, { .i = 5 }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, INTEGER, { .i = 5 }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "minimum-logical-font-size", "Minimum logical font size used to display text", },
- SETTING_BUILTIN, INTEGER, { .i = 5 }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, INTEGER, { .i = 5 }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "monospace-font-family", "Monospace font family used to display text", },
- SETTING_BUILTIN, CHAR, { .p = "monospace" }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = "monospace" }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "print-backgrounds", "Whether background images should be printed", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "resizable-text-areas", "Whether text areas are resizable", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "sans-serif-font-family", "Sans serif font family used to display text", },
- SETTING_BUILTIN, CHAR, { .p = "sans-serif" }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = "sans-serif" }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "serif-font-family", "Serif font family used to display text", },
- SETTING_BUILTIN, CHAR, { .p = "serif" }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = "serif" }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "spell-checking-languages", "Language used for spellchecking sperated by commas", },
- SETTING_BUILTIN, CHAR, { .p = NULL }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = NULL }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "tab-key-cycles-through-elements", "Tab cycles through elements in insert mode", },
- SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, BOOLEAN, { .b = true }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "user-agent", "The user agent string", },
- SETTING_PER_VIEW, CHAR, { .p = NULL }, (S_Func) dwb_set_user_agent, },
+ SETTING_PER_VIEW, CHAR, { .p = NULL }, (S_Func) dwb_set_user_agent, { 0 }, },
{ { "user-stylesheet-uri", "The uri of a stylsheet applied to every page", },
- SETTING_BUILTIN, CHAR, { .p = NULL }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, CHAR, { .p = NULL }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "zoom-step", "The zoom step", },
- SETTING_BUILTIN, DOUBLE, { .d = 0.1 }, (S_Func) dwb_webkit_setting, },
+ SETTING_BUILTIN, DOUBLE, { .d = 0.1 }, (S_Func) dwb_webkit_setting, { 0 }, },
{ { "custom-encoding", "The custom encoding of the tab", },
- SETTING_PER_VIEW, CHAR, { .p = NULL }, (S_Func) dwb_webview_property, },
+ SETTING_PER_VIEW, CHAR, { .p = NULL }, (S_Func) dwb_webview_property, { 0 }, },
{ { "editable", "Whether content can be modified", },
- SETTING_PER_VIEW, BOOLEAN, { .b = false }, (S_Func) dwb_webview_property, },
+ SETTING_PER_VIEW, BOOLEAN, { .b = false }, (S_Func) dwb_webview_property, { 0 }, },
{ { "full-content-zoom", "Whether the full content is scaled when zooming", },
- SETTING_PER_VIEW, BOOLEAN, { .b = false }, (S_Func) dwb_webview_property, },
+ SETTING_PER_VIEW, BOOLEAN, { .b = false }, (S_Func) dwb_webview_property, { 0 }, },
{ { "zoom-level", "The default zoom level", },
- SETTING_PER_VIEW, DOUBLE, { .d = 1.0 }, (S_Func) dwb_webview_property, },
+ SETTING_PER_VIEW, DOUBLE, { .d = 1.0 }, (S_Func) dwb_webview_property, { 0 }, },
{ { "proxy", "Whether to use a HTTP-proxy", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, (S_Func) dwb_set_proxy, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, (S_Func) dwb_set_proxy, { 0 }, },
{ { "proxy-url", "The HTTP-proxy url", },
- SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_soup_init_proxy, },
+ SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_soup_init_proxy, { 0 }, },
{ { "ssl-strict", "Whether to allow only save certificates", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, (S_Func) dwb_soup_init_session_features, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, (S_Func) dwb_soup_init_session_features, { 0 }, },
#ifdef WITH_LIBSOUP_2_38
{ { "ssl-use-system-ca-file", "Whether to use the system certification file", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, (S_Func) dwb_soup_init_session_features, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, (S_Func) dwb_soup_init_session_features, { 0 }, },
#else
{ { "ssl-ca-cert", "Path to ssl-certificate", },
- SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_soup_init_session_features, },
+ SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_soup_init_session_features, { 0 }, },
#endif
{ { "use-ntlm", "Whether to use ntlm-authentication", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, (S_Func) dwb_set_ntlm, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, (S_Func) dwb_set_ntlm, { 0 }, },
{ { "cookies-store-policy", "Whether to store cookies", },
- SETTING_GLOBAL | SETTING_ONINIT, CHAR, { .p = "session" }, (S_Func) dwb_set_cookies, },
+ SETTING_GLOBAL | SETTING_ONINIT, CHAR, { .p = "session" }, (S_Func) dwb_set_cookies, { 0 }, },
{ { "cookies-accept-policy", "Cookies to accept, always never or nothirdparty", },
- SETTING_GLOBAL, CHAR, { .p = "always" }, (S_Func) dwb_set_cookie_accept_policy, },
+ SETTING_GLOBAL, CHAR, { .p = "always" }, (S_Func) dwb_set_cookie_accept_policy, { 0 }, },
{ { "background-tabs", "Whether to open tabs in background", },
- SETTING_GLOBAL | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func) dwb_set_background_tab, },
+ SETTING_GLOBAL | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func) dwb_set_background_tab, { 0 }, },
{ { "scroll-step", "Whether to open tabs in background", },
- SETTING_GLOBAL | SETTING_ONINIT, DOUBLE, { .d = 0 }, (S_Func) dwb_set_scroll_step, },
+ SETTING_GLOBAL | SETTING_ONINIT, DOUBLE, { .d = 0 }, (S_Func) dwb_set_scroll_step, { 0 }, },
{ { "foreground-color", "Foreground color of the active tab", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#ffffff" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#ffffff" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "background-color", "Background color of the active tab", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#000000" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#000000" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tab-active-fg-color", "Foreground color of the active tab", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#ffffff" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#ffffff" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tab-active-bg-color", "Background color of the active tab", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#000000" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#000000" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tab-normal-fg-color-1", "Foreground color of inactive tabs", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#cccccc" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#cccccc" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tab-normal-bg-color-1", "Background color of inactive tabs", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#505050" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#505050" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tab-normal-fg-color-2", "Foreground color of inactive tabs", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#dddddd" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#dddddd" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tab-normal-bg-color-2", "Background color of inactive tabs", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#707070" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#707070" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tab-number-color", "Color of the number in the tab", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#7ac5cd" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#7ac5cd" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tab-protected-color", "Color of the number in the tab", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#ff0000" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#ff0000" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "tabbed-browsing", "Whether to enable tabbed browsing", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, { 0 }, },
{ { "enable-favicon", "Whether to show favicons", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, (S_Func)dwb_set_favicon, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, (S_Func)dwb_set_favicon, { 0 }, },
{ { "sync-files", "Interval to save history and cookies to hdd or 0 to directly write to hdd", },
- SETTING_GLOBAL|SETTING_ONINIT, INTEGER, { .i = 120 }, (S_Func) dwb_set_sync_interval, },
+ SETTING_GLOBAL|SETTING_ONINIT, INTEGER, { .i = 120 }, (S_Func) dwb_set_sync_interval, { 0 }, },
{ { "active-completion-fg-color", "Foreground color of the active tabcompletion item", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#53868b" }, (S_Func) dwb_init_style, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#53868b" }, (S_Func) dwb_init_style, { 0 }, },
{ { "active-completion-bg-color", "Background color of the active tabcompletion item", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#000000" }, (S_Func) dwb_init_style, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#000000" }, (S_Func) dwb_init_style, { 0 }, },
{ { "normal-completion-fg-color", "Foreground color of an inactive tabcompletion item", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#eeeeee" }, (S_Func) dwb_init_style, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#eeeeee" }, (S_Func) dwb_init_style, { 0 }, },
{ { "normal-completion-bg-color", "Background color of an inactive tabcompletion item", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#151515" }, (S_Func) dwb_init_style, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#151515" }, (S_Func) dwb_init_style, { 0 }, },
{ { "ssl-trusted-color", "Color for ssl-encrypted sites, trusted certificate", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#00ff00" }, (S_Func) dwb_init_style, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#00ff00" }, (S_Func) dwb_init_style, { 0 }, },
{ { "ssl-untrusted-color", "Color for ssl-encrypted sites, untrusted certificate", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#ff0000" }, (S_Func) dwb_init_style, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#ff0000" }, (S_Func) dwb_init_style, { 0 }, },
{ { "error-color", "Color for error messages", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#ff0000" }, (S_Func) dwb_init_style, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#ff0000" }, (S_Func) dwb_init_style, { 0 }, },
{ { "prompt-color", "Color for prompt messages", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#00ff00" }, (S_Func) dwb_init_style, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#00ff00" }, (S_Func) dwb_init_style, { 0 }, },
{ { "status-allowed-color", "Color of allowed elements in the statusbar", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#00ff00" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#00ff00" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "status-blocked-color", "Color of blocked elements in the statusbar", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#ffffff" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#ffffff" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "download-bg-color", "Background color of the download label", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#000000" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#000000" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "download-fg-color", "Background color of the download label", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#ffffff" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#ffffff" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "download-gradient-start", "Download start gradient color", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#0000aa" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#0000aa" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "download-gradient-end", "Download end gradient color", },
- SETTING_GLOBAL, COLOR_CHAR, { .p = "#00aa00" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, COLOR_CHAR, { .p = "#00aa00" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "font", "Default font used for the ui", },
- SETTING_GLOBAL, CHAR, { .p = "monospace 8" }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, CHAR, { .p = "monospace 8" }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "font-entry", "Font of the addressbar", },
- SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "font-completion", "Font for tab-completion", },
- SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "font-nofocus", "Font of tabs/completion items without focus", },
- SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_reload_layout, },
+ SETTING_GLOBAL, CHAR, { .p = NULL }, (S_Func) dwb_reload_layout, { 0 }, },
{ { "font-hidden-statusbar", "Font for status elements if statusbar is hidden", },
- SETTING_GLOBAL, CHAR, { .p = "normal 10px helvetica" }, (S_Func) NULL, },
+ SETTING_GLOBAL, CHAR, { .p = "normal 10px helvetica" }, (S_Func) NULL, { 0 }, },
{ { "hint-style", "Whether to use 'letter' or 'number' hints", },
- SETTING_GLOBAL, CHAR, { .p = "letter" }, (S_Func) dwb_init_hints, },
+ SETTING_GLOBAL, CHAR, { .p = "letter" }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-letter-seq", "Letter sequence for letter hints", },
- SETTING_GLOBAL, CHAR, { .p = "FDSARTGBVECWXQYIOPMNHZULKJ" }, (S_Func) dwb_init_hints, },
+ SETTING_GLOBAL, CHAR, { .p = "FDSARTGBVECWXQYIOPMNHZULKJ" }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-highlight-links", "Whether to highlight links in hintmode", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-font", "Font size of hints", },
- SETTING_GLOBAL, CHAR, { .p = "bold 10px monospace" }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, CHAR, { .p = "bold 10px monospace" }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-fg-color", "Foreground color of hints", },
- SETTING_GLOBAL, CHAR, { .p = "#000000" }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, CHAR, { .p = "#000000" }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-bg-color", "Background color of hints", },
- SETTING_GLOBAL, CHAR, { .p = "#ffffff" }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, CHAR, { .p = "#ffffff" }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-active-color", "Color of the active link in hintmode", },
- SETTING_GLOBAL, CHAR, { .p = "#00ff00" }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, CHAR, { .p = "#00ff00" }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-normal-color", "Color of inactive links in hintmode", },
- SETTING_GLOBAL, CHAR, { .p = "#ffff99" }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, CHAR, { .p = "#ffff99" }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-border", "Border used for hints", },
- SETTING_GLOBAL, CHAR, { .p = "1px solid #000000" }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, CHAR, { .p = "1px solid #000000" }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-opacity", "The opacity of hints", },
- SETTING_GLOBAL, DOUBLE, { .d = 0.8 }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, DOUBLE, { .d = 0.8 }, (S_Func) dwb_init_hints, { 0 }, },
{ { "hint-autofollow", "Whether to follow hints automatically if one hint matches", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, (S_Func) dwb_init_hints },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, (S_Func) dwb_init_hints, { 0 }, },
{ { "auto-completion", "Show possible shortcuts", },
- SETTING_GLOBAL | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func)completion_set_autcompletion, },
+ SETTING_GLOBAL | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func)completion_set_autcompletion, { 0 }, },
{ { "startpage", "The default homepage", },
- SETTING_GLOBAL | SETTING_ONINIT, CHAR, { .p = "dwb:bookmarks" }, (S_Func)dwb_set_startpage, },
+ SETTING_GLOBAL | SETTING_ONINIT, CHAR, { .p = "dwb:bookmarks" }, (S_Func)dwb_set_startpage, { 0 }, },
{ { "update-search-delay", "The delay when searching between every keypress", },
- SETTING_GLOBAL | SETTING_ONINIT, INTEGER, { .i = 200 }, (S_Func)dwb_set_find_delay, },
+ SETTING_GLOBAL | SETTING_ONINIT, INTEGER, { .i = 200 }, (S_Func)dwb_set_find_delay, { 0 }, },
{ { "single-instance", "Whether to have only on instance", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, { 0 }, },
{ { "save-session", "Whether to automatically save sessions", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, { 0 }, },
{ { "widget-packing", "Packing of the main widgets", },
- SETTING_GLOBAL, CHAR, { .p = "dtws" }, (S_Func)dwb_set_widget_packing, },
+ SETTING_GLOBAL, CHAR, { .p = "dtws" }, (S_Func)dwb_set_widget_packing, { 0 }, },
{ { "cache-model", "Packing of the main widgets", },
- SETTING_GLOBAL, CHAR, { .p = "webbrowser" }, NULL, },
+ SETTING_GLOBAL, CHAR, { .p = "webbrowser" }, NULL, { 0 }, },
{ { "javascript-schemes", "Whether to allow loading urls with 'javascript' scheme", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, { 0 }, },
/* downloads */
{ { "download-external-command", "External program used for downloads", },
- SETTING_GLOBAL, CHAR, { .p = "xterm -e wget dwb_uri -O dwb_output --load-cookies dwb_cookies" }, NULL, },
+ SETTING_GLOBAL, CHAR, { .p = "xterm -e wget dwb_uri -O dwb_output --load-cookies dwb_cookies" }, NULL, { 0 }, },
{ { "download-no-confirm", "Whether to confirm download directory", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, { 0 }, },
{ { "download-directory", "Default download directory", },
- SETTING_GLOBAL, CHAR, { .p = NULL }, NULL, },
+ SETTING_GLOBAL, CHAR, { .p = NULL }, NULL, { 0 }, },
{ { "download-use-external-program", "Whether to use an external download program", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, { 0 }, },
{ { "complete-history", "Whether to complete browsing history with tab", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, { 0 }, },
{ { "complete-bookmarks", "Whether to complete bookmarks with tab", },
- SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = true }, NULL, { 0 }, },
{ { "complete-searchengines", "Whether to complete searchengines with tab", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, { 0 }, },
{ { "complete-userscripts", "Whether to complete userscripts", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, { 0 }, },
{ { "default-width", "Default width of the window", },
- SETTING_GLOBAL, INTEGER, { .i = 800 }, NULL, },
+ SETTING_GLOBAL, INTEGER, { .i = 800 }, NULL, { 0 }, },
{ { "default-height", "Default height of the window", },
- SETTING_GLOBAL, INTEGER, { .i = 600 }, NULL, },
+ SETTING_GLOBAL, INTEGER, { .i = 600 }, NULL, { 0 }, },
{ { "message-delay", "Time in seconds, messages are shown", },
- SETTING_GLOBAL | SETTING_ONINIT, INTEGER, { .i = 2 }, (S_Func) dwb_set_message_delay, },
+ SETTING_GLOBAL | SETTING_ONINIT, INTEGER, { .i = 2 }, (S_Func) dwb_set_message_delay, { 0 }, },
{ { "history-length", "Length of the browsing history", },
- SETTING_GLOBAL | SETTING_ONINIT, INTEGER, { .i = 500 }, (S_Func) dwb_set_history_length, },
+ SETTING_GLOBAL | SETTING_ONINIT, INTEGER, { .i = 500 }, (S_Func) dwb_set_history_length, { 0 }, },
{ { "navigation-history-max", "Length of the navigation history", },
- SETTING_GLOBAL, INTEGER, { .i = 500 }, (S_Func) NULL, },
+ SETTING_GLOBAL, INTEGER, { .i = 500 }, (S_Func) NULL, { 0 }, },
{ { "scrollbars", "Whether scrollbars should be enabled", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, { 0 }, },
{ { "scheme-handler", "Handler script for unsupported schemes", },
- SETTING_GLOBAL, CHAR, { .p = NULL }, NULL, },
+ SETTING_GLOBAL, CHAR, { .p = NULL }, NULL, { 0 }, },
{ { "editor", "External editor", },
- SETTING_GLOBAL, CHAR, { .p = "xterm -e vim dwb_uri" }, NULL, },
+ SETTING_GLOBAL, CHAR, { .p = "xterm -e vim dwb_uri" }, NULL, { 0 }, },
{ { "adblocker", "Whether to block advertisements via a filterlist", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, (S_Func)dwb_set_adblock, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, (S_Func)dwb_set_adblock, { 0 }, },
{ { "adblocker-filterlist", "Path to a filterlist", },
- SETTING_GLOBAL, CHAR, { .p = NULL }, NULL, },
+ SETTING_GLOBAL, CHAR, { .p = NULL }, NULL, { 0 }, },
#ifdef WITH_LIBSOUP_2_38
{ { "addressbar-dns-lookup", "Whether to perform a dns check for text typed into the address bar", },
- SETTING_GLOBAL | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func)dwb_set_dns_lookup, },
+ SETTING_GLOBAL | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func)dwb_set_dns_lookup, { 0 }, },
#endif
{ { "plugin-blocker", "Whether to block flash plugins and replace them with a clickable element", },
- SETTING_PER_VIEW, BOOLEAN, { .b = true }, (S_Func)dwb_set_plugin_blocker, },
+ SETTING_PER_VIEW, BOOLEAN, { .b = true }, (S_Func)dwb_set_plugin_blocker, { 0 }, },
{ { "plugin-blocker", "Whether to block flash plugins and replace them with a clickable element", },
- SETTING_PER_VIEW, BOOLEAN, { .b = true }, (S_Func)dwb_set_plugin_blocker, },
+ SETTING_PER_VIEW, BOOLEAN, { .b = true }, (S_Func)dwb_set_plugin_blocker, { 0 }, },
{ { "auto-insert-mode", "Whether go automatically in insert mode if input or textarea has focus", },
- SETTING_GLOBAL | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func)dwb_set_auto_insert_mode, },
+ SETTING_GLOBAL | SETTING_ONINIT, BOOLEAN, { .b = false }, (S_Func)dwb_set_auto_insert_mode, { 0 }, },
{ { "tabbar-visible", "Number of seconds the tabbar is shown when switching tabs", },
- SETTING_GLOBAL | SETTING_ONINIT, INTEGER, { .i = 2 }, (S_Func)dwb_set_tabbar_delay, },
+ SETTING_GLOBAL | SETTING_ONINIT, INTEGER, { .i = 2 }, (S_Func)dwb_set_tabbar_delay, { 0 }, },
{ { "new-tab-position-policy", "Number of seconds the tabbar is shown when switching tabs", },
- SETTING_GLOBAL | SETTING_ONINIT, CHAR, { .p = "right", .n = CLOSE_TAB_POSITION_MASK, .i = 0 }, (S_Func)dwb_set_new_tab_position_policy, },
+ SETTING_GLOBAL | SETTING_ONINIT, CHAR, { .p = "right", .n = CLOSE_TAB_POSITION_MASK, .i = 0 }, (S_Func)dwb_set_new_tab_position_policy, { 0 }, },
{ { "close-tab-focus-policy", "Number of seconds the tabbar is shown when switching tabs", },
- SETTING_GLOBAL | SETTING_ONINIT, CHAR, { .p = "left" }, (S_Func)dwb_set_close_tab_position_policy, },
+ SETTING_GLOBAL | SETTING_ONINIT, CHAR, { .p = "left" }, (S_Func)dwb_set_close_tab_position_policy, { 0 }, },
{ { "close-last-tab", "Whether close_tab closes the last tab", },
- SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, },
+ SETTING_GLOBAL, BOOLEAN, { .b = false }, NULL, { 0 }, },
};/*}}}*/
diff --git a/src/download.c b/src/download.c
index 9af8c22d..88515e0f 100644
--- a/src/download.c
+++ b/src/download.c
@@ -201,7 +201,7 @@ download_do_spawn(const char *command, const char *path, const char *mimetype) {
char **argcom = g_strsplit(command, " ", -1);
- int argc=0;
+ guint argc=0;
for (; argc<g_strv_length(argcom) && argc<62; argc++) {
argv[argc] = argcom[argc];
}
@@ -308,7 +308,7 @@ download_cancel(int number) {
return STATUS_OK;
}
for (GList *l = _downloads; l; l=l->next) {
- if (DWB_DOWNLOAD(l)->n == number) {
+ if ((gint)DWB_DOWNLOAD(l)->n == number) {
webkit_download_cancel(DWB_DOWNLOAD(l)->download);
return STATUS_OK;
}
diff --git a/src/dwb.c b/src/dwb.c
index 9eeb618d..bfcf1fc2 100644
--- a/src/dwb.c
+++ b/src/dwb.c
@@ -1163,7 +1163,7 @@ dwb_set_key(const char *prop, char *val) {
if (val)
value.key = dwb_str_to_key(val);
else {
- Key key = { NULL, 0 };
+ Key key = { NULL, 0, 0 };
value.key = key;
}
@@ -2288,7 +2288,7 @@ dwb_eval_key(GdkEventKey *e) {
}
const char *buf = dwb.state.buffer->str;
- int longest = 0;
+ guint longest = 0;
KeyMap *tmp = NULL;
GList *coms = NULL;
for (GSList *l = dwb.custom_commands; l; l=l->next) {
@@ -2695,7 +2695,7 @@ dwb_get_scripts() {
map->key = "";
map->mod = 0;
}
- FunctionMap fm = { { n->first, n->first }, CP_DONT_SAVE | CP_COMMANDLINE | CP_USERSCRIPT, (Func)dwb_execute_user_script, NULL, POST_SM, { .arg = path } };
+ FunctionMap fm = { { n->first, n->first }, CP_DONT_SAVE | CP_COMMANDLINE | CP_USERSCRIPT, (Func)dwb_execute_user_script, NULL, POST_SM, { .arg = path }, EP_NONE, {NULL} };
*fmap = fm;
map->map = fmap;
dwb.misc.userscripts = g_list_prepend(dwb.misc.userscripts, n);
@@ -2994,7 +2994,7 @@ dwb_str_to_key(char *str) {
char **string = g_strsplit(str, " ", -1);
- for (int i=0; i<g_strv_length(string); i++) {
+ for (guint i=0; i<g_strv_length(string); i++) {
if (!g_ascii_strcasecmp(string[i], "Control")) {
key.mod |= GDK_CONTROL_MASK;
}
@@ -3070,7 +3070,7 @@ dwb_keymap_delete(GList *gl, KeyValue key) {
GList *
dwb_keymap_add(GList *gl, KeyValue key) {
gl = dwb_keymap_delete(gl, key);
- for (int i=0; i<LENGTH(FMAP); i++) {
+ for (guint i=0; i<LENGTH(FMAP); i++) {
if (!g_strcmp0(FMAP[i].n.first, key.id)) {
KeyMap *keymap = dwb_malloc(sizeof(KeyMap));
FunctionMap *fmap = &FMAP[i];
@@ -3103,7 +3103,7 @@ dwb_init_key_map() {
fprintf(stderr, "No keyfile found: %s\nUsing default values.\n", error->message);
g_clear_error(&error);
}
- for (int i=0; i<LENGTH(KEYS); i++) {
+ for (guint i=0; i<LENGTH(KEYS); i++) {
KeyValue kv;
char *string = g_key_file_get_value(keyfile, dwb.misc.profile, KEYS[i].id, NULL);
if (string) {
@@ -3164,11 +3164,11 @@ dwb_init_settings() {
}
}
g_free(content);
- for (int j=0; j<LENGTH(DWB_SETTINGS); j++) {
+ for (guint j=0; j<LENGTH(DWB_SETTINGS); j++) {
s = NULL;
value = NULL;
key = g_strdup(DWB_SETTINGS[j].n.first);
- for (int i=0; i<numkeys; i++) {
+ for (guint i=0; i<numkeys; i++) {
value = g_key_file_get_string(keyfile, dwb.misc.profile, keys[i], NULL);
if (!g_strcmp0(keys[i], DWB_SETTINGS[j].n.first)) {
s = dwb_malloc(sizeof(WebSettings));
@@ -3658,7 +3658,7 @@ dwb_handle_signal(int s) {
void
dwb_init_signals() {
- for (int i=0; i<LENGTH(signals); i++) {
+ for (guint i=0; i<LENGTH(signals); i++) {
struct sigaction act, oact;
act.sa_handler = dwb_handle_signal;
diff --git a/src/dwb.h b/src/dwb.h
index 345e43b2..1f310a88 100644
--- a/src/dwb.h
+++ b/src/dwb.h
@@ -229,6 +229,7 @@ typedef enum {
} CompletionType;
typedef enum {
+ SANITIZE_ERROR = -1,
SANITIZE_HISTORY = 1<<0,
SANITIZE_COOKIES = 1<<1,
SANITIZE_CACHE = 1<<2,
diff --git a/src/html.c b/src/html.c
index f8b74ad6..e9a5081a 100644
--- a/src/html.c
+++ b/src/html.c
@@ -500,7 +500,7 @@ html_scripts(GList *gl, HtmlTable *table) {
gboolean
html_load(GList *gl, const char *uri) {
gboolean ret = false;
- for (int i=0; i<LENGTH(table); i++) {
+ for (guint i=0; i<LENGTH(table); i++) {
if (!strncmp(table[i].uri, uri, strlen(table[i].uri))) {
g_strlcpy(current_uri, uri, BUFFER_LENGTH - 1);
if (table[i].func(gl, &table[i]) == STATUS_OK) {
diff --git a/src/plugins.c b/src/plugins.c
index eb52f942..e83a5abc 100644
--- a/src/plugins.c
+++ b/src/plugins.c
@@ -181,7 +181,7 @@ plugins_frame_load_status_cb(WebKitWebFrame *frame, GList *gl) {
/* We have to find the correct frame, but there is no access from the web_frame
* to the Htmlelement */
WebKitDOMNodeList *frames = webkit_dom_document_query_selector_all(doc, "iframe, frame", NULL);
- for (int i=0; i<webkit_dom_node_list_get_length(frames); i++) {
+ for (guint i=0; i<webkit_dom_node_list_get_length(frames); i++) {
WebKitDOMHTMLIFrameElement *iframe = (void*)webkit_dom_node_list_item(frames, i);
char *iframesrc = webkit_dom_html_iframe_element_get_src(iframe);
if (!g_strcmp0(src, iframesrc)) {
@@ -209,7 +209,7 @@ plugins_find_in_frames(WebKitDOMDocument *doc, char *selector) {
/* TODO nodes with duplicate src/data-property */
list = webkit_dom_document_get_elements_by_tag_name(doc, "object");
- for (int i=0; i<webkit_dom_node_list_get_length(list); i++) {
+ for (guint i=0; i<webkit_dom_node_list_get_length(list); i++) {
element = (void*)webkit_dom_node_list_item(list, i);
source = webkit_dom_html_object_element_get_data(WEBKIT_DOM_HTML_OBJECT_ELEMENT(element));
if (!g_strcmp0(selector, source)) {
@@ -220,7 +220,7 @@ plugins_find_in_frames(WebKitDOMDocument *doc, char *selector) {
g_free(source);
}
list = webkit_dom_document_get_elements_by_tag_name(doc, "embed");
- for (int i=0; i<webkit_dom_node_list_get_length(list); i++) {
+ for (guint i=0; i<webkit_dom_node_list_get_length(list); i++) {
element = (void*)webkit_dom_node_list_item(list, i);
source = webkit_dom_html_embed_element_get_src(WEBKIT_DOM_HTML_EMBED_ELEMENT(element));
if (!g_strcmp0(selector, source)) {
@@ -232,7 +232,7 @@ plugins_find_in_frames(WebKitDOMDocument *doc, char *selector) {
}
list = webkit_dom_document_get_elements_by_tag_name(doc, "iframe");
if (list != NULL) {
- for (int i=0; i<webkit_dom_node_list_get_length(list); i++) {
+ for (guint i=0; i<webkit_dom_node_list_get_length(list); i++) {
iframe = (void*)webkit_dom_node_list_item(list, i);
document = webkit_dom_html_iframe_element_get_content_document(iframe);
element = plugins_find_in_frames(document, selector);
diff --git a/src/scripts.c b/src/scripts.c
index c7ae81ba..edae55e5 100644
--- a/src/scripts.c
+++ b/src/scripts.c
@@ -556,7 +556,7 @@ global_bind(JSContextRef ctx, JSObjectRef function, JSObjectRef thisObject, size
Key key = dwb_str_to_key(keystr);
map->key = key.str;
map->mod = key.mod;
- FunctionMap fm = { { NULL, NULL }, CP_DONT_SAVE, (Func)scripts_eval_key, NULL, ALWAYS_SM, { .p = func, .ro = true } };
+ FunctionMap fm = { { NULL, NULL }, CP_DONT_SAVE, (Func)scripts_eval_key, NULL, ALWAYS_SM, { .p = func, .ro = true }, EP_NONE, {NULL} };
*fmap = fm;
map->map = fmap;
dwb.keymap = g_list_prepend(dwb.keymap, map);
diff --git a/src/session.c b/src/session.c
index b2e667dd..4e2caec8 100644
--- a/src/session.c
+++ b/src/session.c
@@ -48,7 +48,7 @@ static char *
session_get_group(const char *name, gboolean *is_marked) {
char *content = NULL;
gboolean mark;
- int l = strlen (name);
+ guint l = strlen (name);
const char *group;
char **groups = session_get_groups();
diff --git a/src/util.c b/src/util.c
index 07f1e465..5949cc6e 100644
--- a/src/util.c
+++ b/src/util.c
@@ -809,7 +809,7 @@ util_string_to_sanitize(const char *string) {
else if (!strcmp(token[i], "allsessions"))
s |= SANITIZE_ALLSESSIONS;
else {
- s = -1;
+ s = SANITIZE_ERROR;
break;
}
}