tlscertificate: add support for certificate chains
[platform/upstream/glib.git] / gio / gproxyaddressenumerator.c
index be54fd0..c34fca9 100644 (file)
@@ -13,9 +13,7 @@
  * Lesser General Public License for more details.
  *
  * You should have received a copy of the GNU Lesser General
- * Public License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
- * Boston, MA 02111-1307, USA.
+ * Public License along with this library; if not, see <http://www.gnu.org/licenses/>.
  *
  * Author: Nicolas Dufresne <nicolas.dufresne@collabora.co.uk>
  */
@@ -39,8 +37,6 @@
 #include "gsocketaddressenumerator.h"
 #include "gsocketconnectable.h"
 
-G_DEFINE_TYPE (GProxyAddressEnumerator, g_proxy_address_enumerator, G_TYPE_SOCKET_ADDRESS_ENUMERATOR);
-
 #define GET_PRIVATE(o) (G_PROXY_ADDRESS_ENUMERATOR (o)->priv)
 
 enum
@@ -77,6 +73,8 @@ struct _GProxyAddressEnumeratorPrivate
   GError                   *last_error;
 };
 
+G_DEFINE_TYPE_WITH_PRIVATE (GProxyAddressEnumerator, g_proxy_address_enumerator, G_TYPE_SOCKET_ADDRESS_ENUMERATOR)
+
 static void
 save_userinfo (GProxyAddressEnumeratorPrivate *priv,
               const gchar *proxy)
@@ -697,9 +695,7 @@ g_proxy_address_enumerator_finalize (GObject *object)
 static void
 g_proxy_address_enumerator_init (GProxyAddressEnumerator *self)
 {
-  self->priv = G_TYPE_INSTANCE_GET_PRIVATE (self,
-                                           G_TYPE_PROXY_ADDRESS_ENUMERATOR,
-                                           GProxyAddressEnumeratorPrivate);
+  self->priv = g_proxy_address_enumerator_get_instance_private (self);
 }
 
 static void
@@ -708,9 +704,6 @@ g_proxy_address_enumerator_class_init (GProxyAddressEnumeratorClass *proxy_enume
   GObjectClass *object_class = G_OBJECT_CLASS (proxy_enumerator_class);
   GSocketAddressEnumeratorClass *enumerator_class = G_SOCKET_ADDRESS_ENUMERATOR_CLASS (proxy_enumerator_class);
 
-  g_type_class_add_private (enumerator_class,
-                           sizeof (GProxyAddressEnumeratorPrivate));
-
   object_class->constructed = g_proxy_address_enumerator_constructed;
   object_class->set_property = g_proxy_address_enumerator_set_property;
   object_class->get_property = g_proxy_address_enumerator_get_property;