[evolution/wip/webkit2] Remove some of the uninitialized variable usages



commit 57a52c7ba4b7e03afbd8ba88cb935eb637f40227
Author: Tomas Popela <tpopela redhat com>
Date:   Mon May 30 14:38:16 2016 +0200

    Remove some of the uninitialized variable usages
    
    And an unused variable.

 e-util/e-html-editor.c                             |    1 -
 .../e-html-editor-selection-dom-functions.c        |    2 +-
 .../composer/e-html-editor-view-dom-functions.c    |    7 ++++---
 3 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/e-util/e-html-editor.c b/e-util/e-html-editor.c
index 7385139..9784c2f 100644
--- a/e-util/e-html-editor.c
+++ b/e-util/e-html-editor.c
@@ -832,7 +832,6 @@ static void
 e_html_editor_init (EHTMLEditor *editor)
 {
        EHTMLEditorPrivate *priv;
-       GtkWidget *widget;
        gchar *filename;
        GError *error = NULL;
 
diff --git a/web-extensions/composer/e-html-editor-selection-dom-functions.c 
b/web-extensions/composer/e-html-editor-selection-dom-functions.c
index 20d86b5..7616d45 100644
--- a/web-extensions/composer/e-html-editor-selection-dom-functions.c
+++ b/web-extensions/composer/e-html-editor-selection-dom-functions.c
@@ -2486,7 +2486,7 @@ wrap_lines (WebKitDOMDocument *document,
            gint length_to_wrap,
            gint word_wrap_length)
 {
-       WebKitDOMNode *node, *start_node, *block_clone;
+       WebKitDOMNode *node, *start_node, *block_clone = NULL;
        gboolean has_selection;
        guint line_length;
        gulong length_left;
diff --git a/web-extensions/composer/e-html-editor-view-dom-functions.c 
b/web-extensions/composer/e-html-editor-view-dom-functions.c
index 1a9b09f..d0e1600 100644
--- a/web-extensions/composer/e-html-editor-view-dom-functions.c
+++ b/web-extensions/composer/e-html-editor-view-dom-functions.c
@@ -7960,7 +7960,7 @@ dom_get_inline_images_data (WebKitDOMDocument *document,
 {
        GVariant *result;
        GVariantBuilder *builder = NULL;
-       GHashTable *added;
+       GHashTable *added = NULL;
        gint length, ii;
        WebKitDOMNodeList *list;
 
@@ -7977,7 +7977,7 @@ dom_get_inline_images_data (WebKitDOMDocument *document,
        added = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_free);
        for (ii = 0; ii < length; ii++) {
                const gchar *id;
-               gchar *cid;
+               gchar *cid = NULL;
                WebKitDOMNode *node = webkit_dom_node_list_item (list, ii);
                gchar *src = webkit_dom_element_get_attribute (
                        WEBKIT_DOM_ELEMENT (node), "src");
@@ -8061,7 +8061,8 @@ dom_get_inline_images_data (WebKitDOMDocument *document,
        }
  out:
        g_object_unref (list);
-       g_hash_table_destroy (added);
+       if (added)
+               g_hash_table_destroy (added);
 
        result = g_variant_new ("asss", builder);
        g_variant_builder_unref (builder);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]