]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
libsoup-2.4: soup_auth_new is not a constructor but a factory method
authorRico Tzschichholz <ricotz@ubuntu.com>
Wed, 21 Aug 2019 18:29:07 +0000 (20:29 +0200)
committerRico Tzschichholz <ricotz@ubuntu.com>
Wed, 21 Aug 2019 18:29:07 +0000 (20:29 +0200)
Fixes https://gitlab.gnome.org/GNOME/vala/issues/791

vapi/libsoup-2.4.vapi
vapi/metadata/Soup-2.4.metadata

index b0bea0e55e1a04be6ea4b18b9ab29251135da431..3d35a23764757a3a95c843ce8a36bc9135e46456 100644 (file)
@@ -148,7 +148,7 @@ namespace Soup {
        [CCode (cheader_filename = "libsoup/soup.h", type_id = "soup_auth_get_type ()")]
        public abstract class Auth : GLib.Object {
                [CCode (has_construct_function = false)]
-               public Auth (GLib.Type type, Soup.Message msg, string auth_header);
+               protected Auth ();
                public virtual void authenticate (string username, string password);
                [Version (since = "2.54")]
                public virtual bool can_authenticate ();
@@ -163,6 +163,7 @@ namespace Soup {
                public void has_saved_password (string username, string password);
                [Version (since = "2.42")]
                public virtual bool is_ready (Soup.Message msg);
+               public static Soup.Auth? @new (GLib.Type type, Soup.Message msg, string auth_header);
                public void save_password (string username, string password);
                public virtual bool update (Soup.Message msg, GLib.HashTable<void*,void*> auth_header);
                [NoAccessorMethod]
index da65956438702f1a21c05f1b74cfd25ee1232d4f..0bb012ddf31fd1b557f781ea7a1c41079347ac2f 100644 (file)
@@ -18,6 +18,9 @@ ProxyResolver deprecated_since="2.28" replacement="ProxyURIResolver"
 
 // Report upstream
 add_* skip=false type="unowned GLib.TimeoutSource"
+Auth
+       // Factory method
+       .new symbol_type="function"
 AuthDomain
        .accepts#method name="accepts_authorization"
 AuthDomainBasic.new skip=false