/pidgin/main: aeaebd2ba4af: Silence more already dismissed cover...

Tomasz Wasilczyk <[email protected]>
Newsgroups gmane.comp.gnome.gaim.cvs
Message-ID <[email protected]>
Changeset: aeaebd2ba4afecb7e709d72a984b7fc98e8f58f9
Author:	 Tomasz Wasilczyk <[email protected]>
Date:	 2014-05-07 00:04 +0200
Branch:	 release-2.x.y
URL: https://hg.pidgin.im/pidgin/main/rev/aeaebd2ba4af

Description:

Silence more already dismissed coverity warnings

diffstat:

 finch/gntnotify.c                    |   2 ++
 libpurple/plugins/perl/perl-common.c |   3 ++-
 libpurple/protocols/msn/msnutils.c   |   2 +-
 libpurple/util.c                     |   1 +
 pidgin/gtknotify.c                   |   4 ++--
 pidgin/gtkstatusbox.c                |  10 +++++++---
 pidgin/plugins/pidginrc.c            |   4 ++--
 7 files changed, 17 insertions(+), 9 deletions(-)

diffs (111 lines):

diff --git a/finch/gntnotify.c b/finch/gntnotify.c
--- a/finch/gntnotify.c
+++ b/finch/gntnotify.c
@@ -63,8 +63,10 @@ finch_notify_common(PurpleNotifyType nty
 	{
 		case PURPLE_NOTIFY_MSG_ERROR:
 			sf |= GNT_TEXT_FLAG_BOLD;
+			/* fall through */
 		case PURPLE_NOTIFY_MSG_WARNING:
 			pf |= GNT_TEXT_FLAG_UNDERLINE;
+			/* fall through */
 		case PURPLE_NOTIFY_MSG_INFO:
 			pf |= GNT_TEXT_FLAG_BOLD;
 			break;
diff --git a/libpurple/plugins/perl/perl-common.c b/libpurple/plugins/perl/perl-common.c
--- a/libpurple/plugins/perl/perl-common.c
+++ b/libpurple/plugins/perl/perl-common.c
@@ -192,7 +192,8 @@ execute_perl(const char *function, int a
 		if (args[i]) {
 			sv_args[i] = sv_2mortal(newSVpv(args[i], 0));
 			XPUSHs(sv_args[i]);
-		}
+		} else
+			sv_args[i] = NULL;
 	}
 
 	PUTBACK;
diff --git a/libpurple/protocols/msn/msnutils.c b/libpurple/protocols/msn/msnutils.c
--- a/libpurple/protocols/msn/msnutils.c
+++ b/libpurple/protocols/msn/msnutils.c
@@ -585,7 +585,7 @@ msn_handle_chl(char *input, char *output
 	len = strlen(buf);
 	if ((len % 8) != 0) {
 		int fix = 8 - (len % 8);
-		memset(&buf[len], '0', fix);
+		strncpy(&buf[len], "00000000", fix);
 		buf[len + fix] = '\0';
 		len += fix;
 	}
diff --git a/libpurple/util.c b/libpurple/util.c
--- a/libpurple/util.c
+++ b/libpurple/util.c
@@ -1194,6 +1194,7 @@ purple_markup_find_tag(const char *needl
 				case '"':
 				case '\'':
 					in_quotes = cur;
+					/* fall through */
 				default:
 					cur++;
 					break;
diff --git a/pidgin/gtknotify.c b/pidgin/gtknotify.c
--- a/pidgin/gtknotify.c
+++ b/pidgin/gtknotify.c
@@ -1706,8 +1706,8 @@ pidgin_create_notification_dialog(Pidgin
 			G_CALLBACK(pounce_response_open_ims), NULL);
 	}
 
-	button = gtk_dialog_add_button(GTK_DIALOG(dialog),
-	                               GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE);
+	gtk_dialog_add_button(GTK_DIALOG(dialog),
+		GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE);
 
 	gtk_label_set_line_wrap(GTK_LABEL(label), TRUE);
 	gtk_misc_set_alignment(GTK_MISC(label), 0, 0);
diff --git a/pidgin/gtkstatusbox.c b/pidgin/gtkstatusbox.c
--- a/pidgin/gtkstatusbox.c
+++ b/pidgin/gtkstatusbox.c
@@ -319,9 +319,9 @@ icon_box_press_cb(GtkWidget *widget, Gdk
 
 		box->icon_box_menu = gtk_menu_new();
 
-		menu_item = pidgin_new_item_from_stock(box->icon_box_menu, _("Select Buddy Icon"), GTK_STOCK_ADD,
-						     G_CALLBACK(choose_buddy_icon_cb),
-						     box, 0, 0, NULL);
+		pidgin_new_item_from_stock(box->icon_box_menu,
+			_("Select Buddy Icon"), GTK_STOCK_ADD,
+			G_CALLBACK(choose_buddy_icon_cb), box, 0, 0, NULL);
 
 		menu_item = pidgin_new_item_from_stock(box->icon_box_menu, _("Remove"), GTK_STOCK_REMOVE,
 						     G_CALLBACK(remove_buddy_icon_cb),
@@ -2724,12 +2724,16 @@ get_statusbox_index(PidginStatusBox *box
 		/* In reverse order */
 		case PURPLE_STATUS_OFFLINE:
 			index++;
+			/* fall through */
 		case PURPLE_STATUS_INVISIBLE:
 			index++;
+			/* fall through */
 		case PURPLE_STATUS_UNAVAILABLE:
 			index++;
+			/* fall through */
 		case PURPLE_STATUS_AWAY:
 			index++;
+			/* fall through */
 		case PURPLE_STATUS_AVAILABLE:
 			index++;
 			break;
diff --git a/pidgin/plugins/pidginrc.c b/pidgin/plugins/pidginrc.c
--- a/pidgin/plugins/pidginrc.c
+++ b/pidgin/plugins/pidginrc.c
@@ -511,8 +511,8 @@ purplerc_make_misc_vbox(void)
 	hbox = gtk_hbox_new(FALSE, PIDGIN_HIG_CAT_SPACE);
 	gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
 
-	check = pidgin_prefs_checkbox(_("Disable Typing Notification Text"),
-			"/plugins/gtk/purplerc/set/disable-typing-notification", hbox);
+	pidgin_prefs_checkbox(_("Disable Typing Notification Text"),
+		"/plugins/gtk/purplerc/set/disable-typing-notification", hbox);
 
 	/* Widget boolean stuff */
 	/*
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.