goto error;
}
-#ifdef GNUTLS_ALPN_MAND
if (alpn != NULL)
{
+#ifdef GNUTLS_ALPN_MAND
gnutls_datum_t *protv = NULL;
unsigned protc = 0;
val = gnutls_alpn_set_protocols (session, protv, protc, 0);
free (protv);
- }
#else
- VLC_UNUSED(alpn);
+ goto error;
#endif
+ }
gnutls_transport_set_int (session, fd);
return -1;
done:
-#ifdef GNUTLS_ALPN_MAND
if (alp != NULL)
{
+#ifdef GNUTLS_ALPN_MAND
gnutls_datum_t datum;
val = gnutls_alpn_get_selected_protocol (session, &datum);
return -1;
}
else
+#endif
*alp = NULL;
}
-#else
- VLC_UNUSED(alp);
-#endif
return 0;
}