aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKjartan Maraas <kmaraas@gnome.org>2007-10-26 16:40:03 +0800
committerKjartan Maraas <kmaraas@src.gnome.org>2007-10-26 16:40:03 +0800
commit5b97425db517f77351ff72380c21e0ff3be77cd3 (patch)
tree260004c4a714adae56b0be4eb56d65ef49a0fb61
parentac2923d34b8eae31908ee1c4611fab81ff5419ba (diff)
downloadgsoc2013-evolution-5b97425db517f77351ff72380c21e0ff3be77cd3.tar.gz
gsoc2013-evolution-5b97425db517f77351ff72380c21e0ff3be77cd3.tar.zst
gsoc2013-evolution-5b97425db517f77351ff72380c21e0ff3be77cd3.zip
Warning fixes: - NULL vs 0 vs FALSE - ANSIfication of declarations - guint
2007-10-26 Kjartan Maraas <kmaraas@gnome.org> * e-component-registry.c: (query_components): * e-component-view.c: (e_component_view_new), (e_component_view_new_controls), (e_component_view_set_title), (e_component_view_set_button_icon): * e-config-upgrade.c: * e-shell-settings-dialog.c: (e_shell_settings_dialog_new): * e-shell-window.c: (component_view_free): * es-event.c: (es_event_peek): * es-menu.c: (es_menu_new): * importer/evolution-importer-client.c: (evolution_importer_client_create_control): Warning fixes: - NULL vs 0 vs FALSE - ANSIfication of declarations - guint for 1-bit bitfields svn path=/trunk/; revision=34430
-rw-r--r--shell/ChangeLog18
-rw-r--r--shell/e-component-registry.c2
-rw-r--r--shell/e-component-view.c8
-rw-r--r--shell/e-config-upgrade.c20
-rw-r--r--shell/e-shell-settings-dialog.c2
-rw-r--r--shell/e-shell-window.c2
-rw-r--r--shell/es-event.c6
-rw-r--r--shell/es-menu.c6
-rw-r--r--shell/importer/evolution-importer-client.c4
9 files changed, 43 insertions, 25 deletions
diff --git a/shell/ChangeLog b/shell/ChangeLog
index 25dabfdd70..df2f3569c9 100644
--- a/shell/ChangeLog
+++ b/shell/ChangeLog
@@ -1,3 +1,21 @@
+2007-10-26 Kjartan Maraas <kmaraas@gnome.org>
+
+ * e-component-registry.c: (query_components):
+ * e-component-view.c: (e_component_view_new),
+ (e_component_view_new_controls), (e_component_view_set_title),
+ (e_component_view_set_button_icon):
+ * e-config-upgrade.c:
+ * e-shell-settings-dialog.c: (e_shell_settings_dialog_new):
+ * e-shell-window.c: (component_view_free):
+ * es-event.c: (es_event_peek):
+ * es-menu.c: (es_menu_new):
+ * importer/evolution-importer-client.c:
+ (evolution_importer_client_create_control):
+ Warning fixes:
+ - NULL vs 0 vs FALSE
+ - ANSIfication of declarations
+ - guint for 1-bit bitfields
+
2007-10-16 Matthew Barnes <mbarnes@redhat.com>
* e-shell-window-commands.c:
diff --git a/shell/e-component-registry.c b/shell/e-component-registry.c
index 6a46ba2376..876412099c 100644
--- a/shell/e-component-registry.c
+++ b/shell/e-component-registry.c
@@ -39,7 +39,7 @@
struct _EComponentRegistryPrivate {
GSList *infos;
- int init:1;
+ guint init:1;
};
G_DEFINE_TYPE (EComponentRegistry, e_component_registry, G_TYPE_OBJECT)
diff --git a/shell/e-component-view.c b/shell/e-component-view.c
index 51b6310ef0..faa9389475 100644
--- a/shell/e-component-view.c
+++ b/shell/e-component-view.c
@@ -96,7 +96,7 @@ e_component_view_init (EComponentView *shell)
EComponentView *e_component_view_new(GNOME_Evolution_ShellView parent, const char *id, struct _GtkWidget *side, struct _GtkWidget *view, struct _GtkWidget *statusbar)
{
EComponentView *new = g_object_new (e_component_view_get_type (), NULL);
- CORBA_Environment ev = { 0 };
+ CORBA_Environment ev = { NULL };
new->id = g_strdup(id);
new->shell_view = CORBA_Object_duplicate(parent, &ev);
@@ -113,7 +113,7 @@ EComponentView *e_component_view_new(GNOME_Evolution_ShellView parent, const cha
EComponentView *e_component_view_new_controls(GNOME_Evolution_ShellView parent, const char *id, BonoboControl *side, BonoboControl *view, BonoboControl *statusbar)
{
EComponentView *new = g_object_new (e_component_view_get_type (), NULL);
- CORBA_Environment ev = { 0 };
+ CORBA_Environment ev = { NULL };
new->id = g_strdup(id);
new->shell_view = CORBA_Object_duplicate(parent, &ev);
@@ -130,7 +130,7 @@ EComponentView *e_component_view_new_controls(GNOME_Evolution_ShellView parent,
void
e_component_view_set_title(EComponentView *ecv, const char *title)
{
- CORBA_Environment ev = { 0 };
+ CORBA_Environment ev = { NULL };
/* save roundtrips, check title is the same */
GNOME_Evolution_ShellView_setTitle(ecv->shell_view, ecv->id, title, &ev);
@@ -140,7 +140,7 @@ e_component_view_set_title(EComponentView *ecv, const char *title)
void
e_component_view_set_button_icon (EComponentView *ecv, const char *iconName)
{
- CORBA_Environment ev = { 0 };
+ CORBA_Environment ev = { NULL };
/* save roundtrips, check title is the same */
GNOME_Evolution_ShellView_setButtonIcon(ecv->shell_view, ecv->id, iconName, &ev);
diff --git a/shell/e-config-upgrade.c b/shell/e-config-upgrade.c
index a95fff37b3..75c6e6228a 100644
--- a/shell/e-config-upgrade.c
+++ b/shell/e-config-upgrade.c
@@ -50,14 +50,14 @@ static e_gconf_map_t importer_elm_map[] = {
/* /Importer/Elm */
{ "mail", "importer/elm/mail", E_GCONF_MAP_BOOL },
{ "mail-imported", "importer/elm/mail-imported", E_GCONF_MAP_BOOL },
- { 0 },
+ { NULL },
};
static e_gconf_map_t importer_pine_map[] = {
/* /Importer/Pine */
{ "mail", "importer/elm/mail", E_GCONF_MAP_BOOL },
{ "address", "importer/elm/address", E_GCONF_MAP_BOOL },
- { 0 },
+ { NULL },
};
static e_gconf_map_t importer_netscape_map[] = {
@@ -65,7 +65,7 @@ static e_gconf_map_t importer_netscape_map[] = {
{ "mail", "importer/netscape/mail", E_GCONF_MAP_BOOL },
{ "settings", "importer/netscape/settings", E_GCONF_MAP_BOOL },
{ "filters", "importer/netscape/filters", E_GCONF_MAP_BOOL },
- { 0 },
+ { NULL },
};
/* ********************************************************************** */
@@ -76,19 +76,19 @@ static e_gconf_map_t shell_views_map[] = {
{ "Width", "shell/view_defaults/width", E_GCONF_MAP_INT },
{ "Height", "shell/view_defaults/height", E_GCONF_MAP_INT },
{ "ViewPanedPosition", "shell/view_defaults/folder_bar/width", E_GCONF_MAP_INT },
- { 0 },
+ { NULL },
};
static e_gconf_map_t offlinefolders_map[] = {
/* /OfflineFolders */
{ "paths", "shell/offline/folder_paths", E_GCONF_MAP_ANYLIST },
- { 0 },
+ { NULL },
};
static e_gconf_map_t shell_map[] = {
/* /Shell */
{ "StartOffline", "shell/start_offline", E_GCONF_MAP_BOOL },
- { 0 },
+ { NULL },
};
/* ********************************************************************** */
@@ -96,13 +96,13 @@ static e_gconf_map_t shell_map[] = {
static e_gconf_map_t addressbook_map[] = {
/* /Addressbook */
{ "select_names_uri", "addressbook/select_names/last_used_uri", E_GCONF_MAP_STRING },
- { 0 },
+ { NULL },
};
static e_gconf_map_t addressbook_completion_map[] = {
/* /Addressbook/Completion */
{ "uris", "addressbook/completion/uris", E_GCONF_MAP_STRING },
- { 0 },
+ { NULL },
};
/* ********************************************************************** */
@@ -114,7 +114,7 @@ static e_gconf_map_t general_map[] = {
/* ********************************************************************** */
-e_gconf_map_list_t remap_list[] = {
+static e_gconf_map_list_t remap_list[] = {
{ "/Importer/Elm", importer_elm_map },
{ "/Importer/Pine", importer_pine_map },
{ "/Importer/Netscape", importer_netscape_map },
@@ -128,7 +128,7 @@ e_gconf_map_list_t remap_list[] = {
{ "/General", general_map },
- { 0 },
+ { NULL },
};
int
diff --git a/shell/e-shell-settings-dialog.c b/shell/e-shell-settings-dialog.c
index e2c720355d..ec6495dde8 100644
--- a/shell/e-shell-settings-dialog.c
+++ b/shell/e-shell-settings-dialog.c
@@ -316,7 +316,7 @@ e_shell_settings_dialog_init (EShellSettingsDialog *dialog)
GtkWidget *
-e_shell_settings_dialog_new ()
+e_shell_settings_dialog_new (void)
{
EShellSettingsDialog *new;
diff --git a/shell/e-shell-window.c b/shell/e-shell-window.c
index 5bf644e8d8..094d090419 100644
--- a/shell/e-shell-window.c
+++ b/shell/e-shell-window.c
@@ -171,7 +171,7 @@ static void
component_view_free (ComponentView *view)
{
if (view->component_view) {
- CORBA_Environment ev = { 0 };
+ CORBA_Environment ev = { NULL };
CORBA_Object_release(view->component_view, &ev);
CORBA_exception_free(&ev);
diff --git a/shell/es-event.c b/shell/es-event.c
index bbdb41b0f8..78847e3f49 100644
--- a/shell/es-event.c
+++ b/shell/es-event.c
@@ -99,7 +99,7 @@ es_event_get_type(void)
ESEvent *es_event_peek(void)
{
if (es_event == NULL) {
- es_event = g_object_new(es_event_get_type(), 0);
+ es_event = g_object_new(es_event_get_type(), NULL);
/** @HookPoint: Shell Events Hookpoint
* Id: org.gnome.evolution.shell.events
*
@@ -159,14 +159,14 @@ static void *emeh_parent_class;
static const EEventHookTargetMask emeh_state_masks[] = {
{ "online", ES_EVENT_STATE_ONLINE },
{ "offline", ES_EVENT_STATE_OFFLINE },
- { 0 }
+ { NULL }
};
static const EEventHookTargetMap emeh_targets[] = {
{ "state", ES_EVENT_TARGET_STATE, emeh_state_masks },
{ "upgrade", ES_EVENT_TARGET_UPGRADE, NULL },
{ "shell", ES_EVENT_TARGET_SHELL, NULL },
- { 0 }
+ { NULL }
};
static void
diff --git a/shell/es-menu.c b/shell/es-menu.c
index 5705ae8ea2..2d62bf16f2 100644
--- a/shell/es-menu.c
+++ b/shell/es-menu.c
@@ -89,7 +89,7 @@ es_menu_get_type(void)
ESMenu *es_menu_new(const char *menuid)
{
- ESMenu *esm = g_object_new(es_menu_get_type(), 0);
+ ESMenu *esm = g_object_new(es_menu_get_type(), NULL);
e_menu_construct(&esm->menu, menuid);
@@ -126,12 +126,12 @@ static void *esph_parent_class;
static const EMenuHookTargetMask esph_shell_masks[] = {
{ "online", ES_MENU_SHELL_ONLINE },
{ "offline", ES_MENU_SHELL_OFFLINE },
- { 0 }
+ { NULL }
};
static const EMenuHookTargetMap esph_targets[] = {
{ "shell", ES_MENU_TARGET_SHELL, esph_shell_masks },
- { 0 }
+ { NULL }
};
static void
diff --git a/shell/importer/evolution-importer-client.c b/shell/importer/evolution-importer-client.c
index 36c2c67158..24ed38b445 100644
--- a/shell/importer/evolution-importer-client.c
+++ b/shell/importer/evolution-importer-client.c
@@ -124,8 +124,8 @@ evolution_importer_client_create_control (EvolutionImporterClient *client)
Bonobo_Control control;
CORBA_Environment ev;
- g_return_val_if_fail (client != NULL, FALSE);
- g_return_val_if_fail (EVOLUTION_IS_IMPORTER_CLIENT (client), FALSE);
+ g_return_val_if_fail (client != NULL, NULL);
+ g_return_val_if_fail (EVOLUTION_IS_IMPORTER_CLIENT (client), NULL);
CORBA_exception_init (&ev);
corba_importer = client->objref;