Revision: 2174 http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=2174&view=re... Author: colombanw Date: 2011-08-27 17:51:57 +0000 (Sat, 27 Aug 2011) Log Message: ----------- Addons: fix a few pedantic warnings
Modified Paths: -------------- trunk/geany-plugins/addons/src/ao_blanklines.c trunk/geany-plugins/addons/src/ao_bookmarklist.c trunk/geany-plugins/addons/src/ao_doclist.c trunk/geany-plugins/addons/src/ao_markword.c trunk/geany-plugins/addons/src/ao_openuri.c trunk/geany-plugins/addons/src/ao_systray.c trunk/geany-plugins/addons/src/ao_tasks.c trunk/geany-plugins/addons/src/ao_xmltagging.c
Modified: trunk/geany-plugins/addons/src/ao_blanklines.c =================================================================== --- trunk/geany-plugins/addons/src/ao_blanklines.c 2011-08-27 17:27:07 UTC (rev 2173) +++ trunk/geany-plugins/addons/src/ao_blanklines.c 2011-08-27 17:51:57 UTC (rev 2174) @@ -31,7 +31,7 @@ const gint maxline = sci_get_line_count(editor->sci) - 1; const gint maxpos = sci_get_line_end_position(editor->sci, maxline);
- gint line, start, end, pos; + gint line, start, end, pos = 0; gchar ch;
/*
Modified: trunk/geany-plugins/addons/src/ao_bookmarklist.c =================================================================== --- trunk/geany-plugins/addons/src/ao_bookmarklist.c 2011-08-27 17:27:07 UTC (rev 2173) +++ trunk/geany-plugins/addons/src/ao_bookmarklist.c 2011-08-27 17:51:57 UTC (rev 2174) @@ -79,7 +79,7 @@ static void ao_bookmark_list_show (AoBookmarkList *bm); static void ao_bookmark_list_hide (AoBookmarkList *bm);
-G_DEFINE_TYPE(AoBookmarkList, ao_bookmark_list, G_TYPE_OBJECT); +G_DEFINE_TYPE(AoBookmarkList, ao_bookmark_list, G_TYPE_OBJECT)
static void ao_bookmark_list_set_property(GObject *object, guint prop_id,
Modified: trunk/geany-plugins/addons/src/ao_doclist.c =================================================================== --- trunk/geany-plugins/addons/src/ao_doclist.c 2011-08-27 17:27:07 UTC (rev 2173) +++ trunk/geany-plugins/addons/src/ao_doclist.c 2011-08-27 17:51:57 UTC (rev 2174) @@ -68,7 +68,7 @@ static void ao_doclist_set_property(GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec);
-G_DEFINE_TYPE(AoDocList, ao_doc_list, G_TYPE_OBJECT); +G_DEFINE_TYPE(AoDocList, ao_doc_list, G_TYPE_OBJECT)
static void ao_doc_list_class_init(AoDocListClass *klass)
Modified: trunk/geany-plugins/addons/src/ao_markword.c =================================================================== --- trunk/geany-plugins/addons/src/ao_markword.c 2011-08-27 17:27:07 UTC (rev 2173) +++ trunk/geany-plugins/addons/src/ao_markword.c 2011-08-27 17:51:57 UTC (rev 2174) @@ -59,7 +59,7 @@
static void ao_mark_word_finalize (GObject *object);
-G_DEFINE_TYPE(AoMarkWord, ao_mark_word, G_TYPE_OBJECT); +G_DEFINE_TYPE(AoMarkWord, ao_mark_word, G_TYPE_OBJECT)
static void ao_mark_word_set_property(GObject *object, guint prop_id,
Modified: trunk/geany-plugins/addons/src/ao_openuri.c =================================================================== --- trunk/geany-plugins/addons/src/ao_openuri.c 2011-08-27 17:27:07 UTC (rev 2173) +++ trunk/geany-plugins/addons/src/ao_openuri.c 2011-08-27 17:51:57 UTC (rev 2174) @@ -66,7 +66,7 @@ const GValue *value, GParamSpec *pspec);
-G_DEFINE_TYPE(AoOpenUri, ao_open_uri, G_TYPE_OBJECT); +G_DEFINE_TYPE(AoOpenUri, ao_open_uri, G_TYPE_OBJECT)
@@ -243,7 +243,7 @@ if (sci_has_selection(doc->editor->sci)) { gint len = sci_get_selected_text_length(doc->editor->sci); - text = g_malloc0(len + 1); + text = g_malloc0((guint)len + 1); sci_get_selected_text(doc->editor->sci, text); } else @@ -252,7 +252,7 @@ /* TODO be more restrictive when handling selections as there are too many hits by now */ if (text != NULL && (ao_uri_has_scheme(text) || ao_uri_is_link(text))) { - guint len = strlen(text); + gsize len = strlen(text); /* remove trailing dots and colons */ if (text[len - 1] == '.' || text[len - 1] == ':') text[len - 1] = '\0';
Modified: trunk/geany-plugins/addons/src/ao_systray.c =================================================================== --- trunk/geany-plugins/addons/src/ao_systray.c 2011-08-27 17:27:07 UTC (rev 2173) +++ trunk/geany-plugins/addons/src/ao_systray.c 2011-08-27 17:51:57 UTC (rev 2174) @@ -63,7 +63,7 @@ WIDGET_PREFERENCES };
-G_DEFINE_TYPE(AoSystray, ao_systray, G_TYPE_OBJECT); +G_DEFINE_TYPE(AoSystray, ao_systray, G_TYPE_OBJECT)
static void ao_systray_finalize(GObject *object) @@ -134,7 +134,7 @@ static void icon_popup_menu_cmd_clicked_cb(GtkMenuItem *item, gpointer data) { GtkWidget *widget; - const gchar *widget_name; + const gchar *widget_name = NULL; switch (GPOINTER_TO_INT(data)) {
Modified: trunk/geany-plugins/addons/src/ao_tasks.c =================================================================== --- trunk/geany-plugins/addons/src/ao_tasks.c 2011-08-27 17:27:07 UTC (rev 2173) +++ trunk/geany-plugins/addons/src/ao_tasks.c 2011-08-27 17:51:57 UTC (rev 2174) @@ -93,7 +93,7 @@ static void ao_tasks_show (AoTasks *t); static void ao_tasks_hide (AoTasks *t);
-G_DEFINE_TYPE(AoTasks, ao_tasks, G_TYPE_OBJECT); +G_DEFINE_TYPE(AoTasks, ao_tasks, G_TYPE_OBJECT)
static void ao_tasks_set_property(GObject *object, guint prop_id, @@ -551,7 +551,7 @@
static void update_tasks_for_doc(AoTasks *t, GeanyDocument *doc) { - guint lines, line; + gint lines, line; gchar *line_buf, *display_name, *task_start; gchar **token; AoTasksPrivate *priv = AO_TASKS_GET_PRIVATE(t); @@ -611,7 +611,7 @@ AoTasksPrivate *priv = AO_TASKS_GET_PRIVATE(data); gint line, selected_line; gchar *filename = NULL; - gchar *selected_filename = NULL; + const gchar *selected_filename = NULL; gboolean ret = FALSE;
if (priv->scan_all_documents)
Modified: trunk/geany-plugins/addons/src/ao_xmltagging.c =================================================================== --- trunk/geany-plugins/addons/src/ao_xmltagging.c 2011-08-27 17:27:07 UTC (rev 2173) +++ trunk/geany-plugins/addons/src/ao_xmltagging.c 2011-08-27 17:51:57 UTC (rev 2174) @@ -88,7 +88,7 @@ tag = g_strdup(gtk_entry_get_text(GTK_ENTRY(textbox))); if (NZV(tag)) { - gint end = 0; + gsize end = 0; GString *tmp = NULL; const gchar *end_tag;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
plugins-commits@lists.geany.org