[balsa/52-fix-clang-9-fails] libbalsa/imap: Fix a clang-9 issue
- From: Peter Bloomfield <peterb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [balsa/52-fix-clang-9-fails] libbalsa/imap: Fix a clang-9 issue
- Date: Sun, 10 Jan 2021 23:50:26 +0000 (UTC)
commit 3b0bbca766ab4624b73adb40833cda195e95eabc
Author: Peter Bloomfield <PeterBloomfield bellsouth net>
Date: Sun Jan 10 18:43:24 2021 -0500
libbalsa/imap: Fix a clang-9 issue
with using G_DECLARE_FINAL_TYPE for ImapMboxHandle.
Well, it is not really a clang-9 issue, it is all about redefinition of
a typedef, which is a C-11 feature.
modified: libbalsa/imap/imap-handle.c
modified: libbalsa/imap/libimap.h
libbalsa/imap/imap-handle.c | 6 ------
libbalsa/imap/libimap.h | 11 +++++++----
2 files changed, 7 insertions(+), 10 deletions(-)
---
diff --git a/libbalsa/imap/imap-handle.c b/libbalsa/imap/imap-handle.c
index 625a121eb..5f112f090 100644
--- a/libbalsa/imap/imap-handle.c
+++ b/libbalsa/imap/imap-handle.c
@@ -69,12 +69,6 @@ static gboolean async_process(GSocket *source,
GIOCondition condition,
gpointer data);
-G_DECLARE_FINAL_TYPE(ImapMboxHandle,
- imap_mbox_handle,
- IMAP,
- MBOX_HANDLE,
- GObject)
-
G_DEFINE_TYPE(ImapMboxHandle, imap_mbox_handle, G_TYPE_OBJECT)
static void
diff --git a/libbalsa/imap/libimap.h b/libbalsa/imap/libimap.h
index 1382e5721..2a42fce75 100644
--- a/libbalsa/imap/libimap.h
+++ b/libbalsa/imap/libimap.h
@@ -17,8 +17,13 @@
* along with this program; if not, see <https://www.gnu.org/licenses/>.
*/
-#include <time.h>
-#include <glib.h>
+#include <glib-object.h>
+
+G_DECLARE_FINAL_TYPE(ImapMboxHandle,
+ imap_mbox_handle,
+ IMAP,
+ MBOX_HANDLE,
+ GObject);
/* connection states, as defined in rfc-2060, 3 */
typedef enum {
@@ -228,8 +233,6 @@ typedef struct ImapMessage_ {
* in question is not present. */
} ImapMessage;
-typedef struct _ImapMboxHandle ImapMboxHandle;
-
ImapEnvelope *imap_envelope_new(void);
void imap_envelope_free(ImapEnvelope *);
gchar* imap_envelope_to_string(const ImapEnvelope* env);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]