[balsa] address-book: Adopt ab as the identifier
- From: Peter Bloomfield <peterb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [balsa] address-book: Adopt ab as the identifier
- Date: Wed, 15 May 2019 19:12:40 +0000 (UTC)
commit cb4002e9e243e572e8135e427e15ab799826760b
Author: Peter Bloomfield <PeterBloomfield bellsouth net>
Date: Wed May 15 13:53:46 2019 -0400
address-book: Adopt ab as the identifier
* libbalsa/address-book.c (libbalsa_address_book_new_from_config):
* libbalsa/address-book.h:
ChangeLog | 7 +++++++
libbalsa/address-book.c | 15 +++++++--------
libbalsa/address-book.h | 4 +---
3 files changed, 15 insertions(+), 11 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index d4f2b1181..aedf30d82 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2019-05-15 Peter Bloomfield <pbloomfield bellsouth net>
+
+ address-book: Adopt ab as the identifier
+
+ * libbalsa/address-book.c (libbalsa_address_book_new_from_config):
+ * libbalsa/address-book.h:
+
2019-05-15 Peter Bloomfield <pbloomfield bellsouth net>
Use G_DECLARE_FINAL_TYPE to declare LibBalsaAddressBookExternq
diff --git a/libbalsa/address-book.c b/libbalsa/address-book.c
index 7bcc85a4b..e36f04892 100644
--- a/libbalsa/address-book.c
+++ b/libbalsa/address-book.c
@@ -105,7 +105,7 @@ libbalsa_address_book_new_from_config(const gchar * group)
gchar *type_str;
GType type;
gboolean got_default;
- LibBalsaAddressBook *address_book = NULL;
+ LibBalsaAddressBook *ab = NULL;
libbalsa_conf_push_group(group);
type_str = libbalsa_conf_get_string_with_default("Type", &got_default);
@@ -113,7 +113,7 @@ libbalsa_address_book_new_from_config(const gchar * group)
if (got_default == TRUE) {
/* type entry missing, skip it */
libbalsa_conf_pop_group();
- return NULL;
+ return ab;
}
type = g_type_from_name(type_str);
@@ -121,17 +121,16 @@ libbalsa_address_book_new_from_config(const gchar * group)
/* type unknown, skip it */
g_free(type_str);
libbalsa_conf_pop_group();
- return NULL;
+ return ab;
}
- address_book = g_object_new(type, NULL);
- libbalsa_address_book_load_config(address_book, group);
+ ab = g_object_new(type, NULL);
+ libbalsa_address_book_load_config(ab, group);
- libbalsa_conf_pop_group();
g_free(type_str);
+ libbalsa_conf_pop_group();
- return address_book;
-
+ return ab;
}
LibBalsaABErr
diff --git a/libbalsa/address-book.h b/libbalsa/address-book.h
index 82d115aa3..70efa1b3e 100644
--- a/libbalsa/address-book.h
+++ b/libbalsa/address-book.h
@@ -70,8 +70,6 @@ struct _LibBalsaAddressBookClass {
GList* (*alias_complete) (LibBalsaAddressBook * ab, const gchar *prefix);
};
-GType libbalsa_address_book_get_type(void);
-
LibBalsaAddressBook *libbalsa_address_book_new_from_config(const gchar *
prefix);
@@ -113,7 +111,7 @@ const gchar* libbalsa_address_book_strerror(LibBalsaAddressBook * ab,
and for freeing the list.
*/
-GList *libbalsa_address_book_alias_complete(LibBalsaAddressBook * ab,
+GList *libbalsa_address_book_alias_complete(LibBalsaAddressBook * ab,
const gchar *prefix);
gboolean libbalsa_address_is_dist_list(LibBalsaAddressBook *ab,
LibBalsaAddress *address);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]