Commit 3e8acc53 authored by Ian Goldberg's avatar Ian Goldberg
Browse files

Build cleanly with -Wall -Wextra -Wno-unused-parameter...

Build cleanly with -Wall -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -Wformat-security
parent 01745ac5
2012-08-22
* configure.ac:
* Makefile.mingw: Use gcc and ld hardening flags, where possible.
* patches/win32/rndw32.c:
* patches/win32/libgcrypt-config.h.patch: Include required win32
build patches right here in the source tree
* INSTALL.mingw: Be much more thorough in describing how to
cross-compile pidgin-otr.dll on Linux
* configure.ac:
* gtk-dialog.c: Build cleanly with -Wall -Wextra
-Wno-unused-parameter -Wno-missing-field-initializers
-Wformat-security
2012-08-16
* packaging/windows/pidgin-otr.nsi: Modifications to the nsi
......
......@@ -145,6 +145,13 @@ if test x$enable_gcc_hardening != xno; then
OTR_CHECK_CFLAGS(-Wstack-protector)
OTR_CHECK_CFLAGS(-fwrapv)
OTR_CHECK_CFLAGS(--param ssp-buffer-size=1)
dnl Ian added the next four:
OTR_CHECK_CFLAGS(-fno-strict-overflow)
OTR_CHECK_CFLAGS(-Wall)
OTR_CHECK_CFLAGS(-Wextra -Wno-unused-parameter -Wno-missing-field-initializers)
OTR_CHECK_CFLAGS(-Wformat-security)
if test "$bwin32" = "false"; then
OTR_CHECK_CFLAGS(-fPIE)
OTR_CHECK_LDFLAGS(-pie, "$all_ldflags_for_check", "$all_libs_for_check")
......
......@@ -2316,7 +2316,7 @@ static void otr_add_buddy_instances_top_menu(PidginConversation *gtkconv,
GtkWidget * tooltip_menu;
gchar *tooltip_text;
gpointer gp_instance;
otrl_instag_t * selected_instance;
otrl_instag_t * selected_instance = NULL;
gboolean selection_exists = 0;
ConnContext * context = instances->data;
TrustLevel level = TRUST_NOT_PRIVATE;
......@@ -2712,7 +2712,7 @@ static void otr_check_conv_status_change( PurpleConversation *conv) {
ConnContext *context = otrg_plugin_conv_to_context(conv,
OTRL_INSTAG_RECENT, 0);
int *previous_level;
TrustLevel *previous_level;
char *buf;
char *status = "";
......@@ -3059,7 +3059,7 @@ static char* conversation_timestamp(PurpleConversation *conv, time_t mtime,
TrustLevel current_level = TRUST_NOT_PRIVATE;
ConnContext *context = (ConnContext *) otrg_plugin_conv_to_context(conv,
OTRL_INSTAG_RECENT, 0);
int *previous_level;
TrustLevel *previous_level;
int id;
......@@ -3078,7 +3078,7 @@ static char* conversation_timestamp(PurpleConversation *conv, time_t mtime,
* level we received corresponds to the active conversation. */
if (conv == gtkconv->active_conv) {
/* 'free' is handled by the hashtable */
int * current_level_ptr = malloc(sizeof(int));
TrustLevel * current_level_ptr = malloc(sizeof(TrustLevel));
*current_level_ptr = current_level;
g_hash_table_replace ( otr_win_status, gtkconv, current_level_ptr );
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment