summaryrefslogtreecommitdiff
path: root/gcr
diff options
context:
space:
mode:
authorNiels De Graef <nielsdegraef@gmail.com>2020-03-31 15:04:48 +0200
committerNiels De Graef <nielsdegraef@gmail.com>2020-03-31 15:11:06 +0200
commit7c5deaf90e6bb87101d43265e6e9fff1cf1c1fa6 (patch)
tree126d9bdd401c154454bf1ffc902bb14fbee40eca /gcr
parent3c2ea60162495f593e86de5ba0f623c99bb11f3d (diff)
downloadgcr-7c5deaf90e6bb87101d43265e6e9fff1cf1c1fa6.tar.gz
gcr: Cleanup with G_DEFINE_BOXED_TYPE
Diffstat (limited to 'gcr')
-rw-r--r--gcr/gcr-parser.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/gcr/gcr-parser.c b/gcr/gcr-parser.c
index 288a3f1..f841535 100644
--- a/gcr/gcr-parser.c
+++ b/gcr/gcr-parser.c
@@ -2747,19 +2747,7 @@ gcr_parser_get_parsed (GcrParser *self)
return self->pv->parsed;
}
-GType
-gcr_parsed_get_type (void)
-{
- static volatile gsize initialized = 0;
- static GType type = 0;
- if (g_once_init_enter (&initialized)) {
- type = g_boxed_type_register_static ("GcrParsed",
- (GBoxedCopyFunc)gcr_parsed_ref,
- (GBoxedFreeFunc)gcr_parsed_unref);
- g_once_init_leave (&initialized, 1);
- }
- return type;
-}
+G_DEFINE_BOXED_TYPE (GcrParsed, gcr_parsed, gcr_parsed_ref, gcr_parsed_unref)
/**
* gcr_parser_get_filename: