gresolver: Mark GResolver as an abstract class

It only works through its virtual methods, so while it could be
instantiated before (and this is technically an API break), any instance
of it would previously have crashed as soon as any of its methods were
called anyway.

If anybody has any problems with this ABI break, please make them known
during the 2.51 unstable development cycle and it can be reverted.

https://bugzilla.gnome.org/show_bug.cgi?id=772255
This commit is contained in:
Philip Withnall 2016-09-30 14:41:12 +02:00
parent bd9e266e11
commit 10bac98185

View File

@ -72,8 +72,11 @@ struct _GResolverPrivate {
*
* The object that handles DNS resolution. Use g_resolver_get_default()
* to get the default resolver.
*
* This is an abstract type; subclasses of it implement different resolvers for
* different platforms and situations.
*/
G_DEFINE_TYPE_WITH_CODE (GResolver, g_resolver, G_TYPE_OBJECT,
G_DEFINE_ABSTRACT_TYPE_WITH_CODE (GResolver, g_resolver, G_TYPE_OBJECT,
G_ADD_PRIVATE (GResolver)
g_networking_init ();)