diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2009-10-25 05:55:54 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2009-10-27 21:25:01 +0800 |
commit | 58166e645971a4812fef23702f45cacc8e64e419 (patch) | |
tree | bedad70e39e2215a53105e0303c168e86140371a /modules/mail | |
parent | c58b70659747967568a536e217b9440424709f92 (diff) | |
download | gsoc2013-evolution-58166e645971a4812fef23702f45cacc8e64e419.tar.gz gsoc2013-evolution-58166e645971a4812fef23702f45cacc8e64e419.tar.zst gsoc2013-evolution-58166e645971a4812fef23702f45cacc8e64e419.zip |
Prefer G_N_ELEMENTS over sizeof calculations.
Diffstat (limited to 'modules/mail')
-rw-r--r-- | modules/mail/e-mail-shell-migrate.c | 2 | ||||
-rw-r--r-- | modules/mail/em-mailer-prefs.c | 2 | ||||
-rw-r--r-- | modules/mail/em-network-prefs.c | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/modules/mail/e-mail-shell-migrate.c b/modules/mail/e-mail-shell-migrate.c index 967f80053f..43cd1a5185 100644 --- a/modules/mail/e-mail-shell-migrate.c +++ b/modules/mail/e-mail-shell-migrate.c @@ -1670,7 +1670,7 @@ em_migrate_folder(EMMigrateSession *session, const gchar *dirname, const gchar * } /* copy over the metadata files */ - for (i = 0; i < sizeof(meta_ext)/sizeof(meta_ext[0]); i++) { + for (i = 0; i < G_N_ELEMENTS (meta_ext); i++) { g_string_truncate (src, slen); g_string_truncate (dest, dlen); diff --git a/modules/mail/em-mailer-prefs.c b/modules/mail/em-mailer-prefs.c index 630f77563f..03f8973ab4 100644 --- a/modules/mail/em-mailer-prefs.c +++ b/modules/mail/em-mailer-prefs.c @@ -845,7 +845,7 @@ em_mailer_prefs_construct (EMMailerPrefs *prefs, */ ec = em_config_new(E_CONFIG_BOOK, "org.gnome.evolution.mail.prefs"); l = NULL; - for (i=0;i<sizeof(emmp_items)/sizeof(emmp_items[0]);i++) + for (i = 0; i < G_N_ELEMENTS (emmp_items); i++) l = g_slist_prepend(l, &emmp_items[i]); e_config_add_items((EConfig *)ec, l, NULL, NULL, emmp_free, prefs); diff --git a/modules/mail/em-network-prefs.c b/modules/mail/em-network-prefs.c index f2d21545bd..5c6c511b72 100644 --- a/modules/mail/em-network-prefs.c +++ b/modules/mail/em-network-prefs.c @@ -323,7 +323,7 @@ em_network_prefs_construct (EMNetworkPrefs *prefs) */ ec = em_config_new(E_CONFIG_BOOK, "org.gnome.evolution.mail.networkPrefs"); l = NULL; - for (i=0;i<sizeof(emnp_items)/sizeof(emnp_items[0]);i++) + for (i = 0; i < G_N_ELEMENTS (emnp_items); i++) l = g_slist_prepend(l, &emnp_items[i]); e_config_add_items((EConfig *)ec, l, NULL, NULL, emnp_free, prefs); |