# HG changeset patch # User Stu Tomlinson # Date 1197993366 0 # Node ID 03c950701fac37df009b91a943541d177fdd4147 # Parent 886fa5f83f917c8e18cc4543ae4f3fc9f0b53765 Move some curly braces around so static analysis tools can properly detect functions without having to preprocess the source diff -r 886fa5f83f91 -r 03c950701fac libpurple/ft.c --- a/libpurple/ft.c Tue Dec 18 15:53:05 2007 +0000 +++ b/libpurple/ft.c Tue Dec 18 15:56:06 2007 +0000 @@ -479,10 +479,11 @@ /* Sending a file */ /* Check the filename. */ #ifdef _WIN32 - if (g_strrstr(filename, "../") || g_strrstr(filename, "..\\")) { + if (g_strrstr(filename, "../") || g_strrstr(filename, "..\\")) #else - if (g_strrstr(filename, "../")) { + if (g_strrstr(filename, "../")) #endif + { char *utf8 = g_filename_to_utf8(filename, -1, NULL, NULL, NULL); msg = g_strdup_printf(_("%s is not a valid filename.\n"), utf8); diff -r 886fa5f83f91 -r 03c950701fac libpurple/log.c --- a/libpurple/log.c Tue Dec 18 15:53:05 2007 +0000 +++ b/libpurple/log.c Tue Dec 18 15:56:06 2007 +0000 @@ -348,7 +348,6 @@ void(*get_log_sets)(PurpleLogSetCallback cb, GHashTable *sets), gboolean(*remove)(PurpleLog *log), gboolean(*is_deletable)(PurpleLog *log)) -{ #endif PurpleLogLogger *logger; va_list args; diff -r 886fa5f83f91 -r 03c950701fac libpurple/protocols/msn/soap.c --- a/libpurple/protocols/msn/soap.c Tue Dec 18 15:53:05 2007 +0000 +++ b/libpurple/protocols/msn/soap.c Tue Dec 18 15:56:06 2007 +0000 @@ -813,10 +813,8 @@ purple_debug_info("MSN SOAP", "Currently processing another SOAP request\n"); } else { purple_debug_info("MSN SOAP", "No requests left to dispatch\n"); +#endif } -#else - } -#endif } diff -r 886fa5f83f91 -r 03c950701fac pidgin/gtkimhtml.c --- a/pidgin/gtkimhtml.c Tue Dec 18 15:53:05 2007 +0000 +++ b/pidgin/gtkimhtml.c Tue Dec 18 15:56:06 2007 +0000 @@ -1136,14 +1136,13 @@ #ifdef _WIN32 /* If we're on windows, let's see if we can get data from the HTML Format clipboard before we try to paste from the GTK buffer */ - if (!clipboard_paste_html_win32(imhtml)) { + if (!clipboard_paste_html_win32(imhtml)) #endif + { GtkClipboard *clipboard = gtk_widget_get_clipboard(GTK_WIDGET(imhtml), GDK_SELECTION_CLIPBOARD); gtk_clipboard_request_contents(clipboard, gdk_atom_intern("text/html", FALSE), paste_received_cb, imhtml); -#ifdef _WIN32 } -#endif g_signal_stop_emission_by_name(imhtml, "paste-clipboard"); } @@ -3483,6 +3482,9 @@ return; } #endif /* FILECHOOSER */ +#if 0 /* mismatched curly braces */ + } +#endif /* * XXX - We should probably prompt the user to determine if they really diff -r 886fa5f83f91 -r 03c950701fac pidgin/gtkimhtmltoolbar.c --- a/pidgin/gtkimhtmltoolbar.c Tue Dec 18 15:53:05 2007 +0000 +++ b/pidgin/gtkimhtmltoolbar.c Tue Dec 18 15:56:06 2007 +0000 @@ -467,10 +467,11 @@ GtkTextMark *ins; #if GTK_CHECK_VERSION(2,4,0) /* FILECHOOSER */ - if (response != GTK_RESPONSE_ACCEPT) { + if (response != GTK_RESPONSE_ACCEPT) #else /* FILECHOOSER */ - if (response != GTK_RESPONSE_OK) { + if (response != GTK_RESPONSE_OK) #endif /* FILECHOOSER */ + { gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toolbar->image), FALSE); return; } diff -r 886fa5f83f91 -r 03c950701fac pidgin/gtkrequest.c --- a/pidgin/gtkrequest.c Tue Dec 18 15:53:05 2007 +0000 +++ b/pidgin/gtkrequest.c Tue Dec 18 15:56:06 2007 +0000 @@ -1502,7 +1502,9 @@ } #endif /* FILECHOOSER */ - +#if 0 /* mismatched curly braces */ + } +#endif if ((data->u.file.savedialog == TRUE) && (g_file_test(data->u.file.name, G_FILE_TEST_EXISTS))) { purple_request_action(data, NULL, _("That file already exists"), diff -r 886fa5f83f91 -r 03c950701fac pidgin/gtkutils.c --- a/pidgin/gtkutils.c Tue Dec 18 15:53:05 2007 +0000 +++ b/pidgin/gtkutils.c Tue Dec 18 15:56:06 2007 +0000 @@ -2306,6 +2306,9 @@ } #endif /* FILECHOOSER */ +#if 0 /* mismatched curly braces */ + } +#endif if (dialog->callback) dialog->callback(filename, dialog->data); gtk_widget_destroy(dialog->icon_filesel);