Merge lp:~online-accounts/libsignon-glib/packaging into lp:libsignon-glib

Proposed by Alberto Mardegan
Status: Merged
Approved by: David Barth
Approved revision: no longer in the source branch.
Merged at revision: 150
Proposed branch: lp:~online-accounts/libsignon-glib/packaging
Merge into: lp:libsignon-glib
Diff against target: 354 lines (+79/-44)
8 files modified
NEWS (+14/-0)
configure.ac (+1/-1)
debian/changelog (+14/-0)
libsignon-glib/signon-auth-service.c (+2/-2)
libsignon-glib/signon-auth-session.c (+16/-21)
libsignon-glib/signon-identity.h (+1/-1)
libsignon-glib/signon.vapi (+17/-15)
tests/check_signon.c (+14/-4)
To merge this branch: bzr merge lp:~online-accounts/libsignon-glib/packaging
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Needs Fixing
David Barth (community) Approve
Review via email: mp+244098@code.launchpad.net

Commit message

New upstream release

- Introspection: fix transfer type of some methods
- Update VALA bindings (bug 1382843)

Description of the change

New upstream release

- Introspection: fix transfer type of some methods
- Update VALA bindings (bug 1382843)

To post a comment you must log in.
Revision history for this message
David Barth (dbarth) :
review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
150. By Alberto Mardegan

New upstream release

- Introspection: fix transfer type of some methods
- Update VALA bindings (bug 1382843)

Approved by: David Barth

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'NEWS'
--- NEWS 2013-06-05 11:28:59 +0000
+++ NEWS 2014-12-09 13:40:34 +0000
@@ -1,5 +1,19 @@
1libsignon-glib NEWS1libsignon-glib NEWS
22
3Version 1.12
4------------
5
6* Introspection: fix transfer type of some methods
7* Update VALA bindings
8
9Version 1.11
10------------
11
12* Disconnect from signals when the remote AuthSession dies
13 http://code.google.com/p/accounts-sso/issues/detail?id=229
14* Avoid unreferencing a NULL GVariant
15* Fix the linking problem when using check
16
3Version 1.1017Version 1.10
4------------18------------
519
620
=== modified file 'configure.ac'
--- configure.ac 2013-06-21 14:46:21 +0000
+++ configure.ac 2014-12-09 13:40:34 +0000
@@ -1,7 +1,7 @@
1dnl Process this file with autoconf to produce a configure script.1dnl Process this file with autoconf to produce a configure script.
2AC_PREREQ([2.64])2AC_PREREQ([2.64])
3AC_INIT([libsignon-glib],3AC_INIT([libsignon-glib],
4 [1.10],4 [1.12],
5 [http://code.google.com/p/accounts-sso/issues/entry],5 [http://code.google.com/p/accounts-sso/issues/entry],
6 [libsignon-glib],6 [libsignon-glib],
7 [http://code.google.com/p/accounts-sso/])7 [http://code.google.com/p/accounts-sso/])
88
=== modified file 'debian/changelog'
--- debian/changelog 2013-06-25 04:31:09 +0000
+++ debian/changelog 2014-12-09 13:40:34 +0000
@@ -1,3 +1,17 @@
1libsignon-glib (1.12-0ubuntu1) UNRELEASED; urgency=medium
2
3 * New upstream release.
4 - Introspection: fix transfer type of some methods
5 - Update VALA bindings (LP: #1382843)
6
7 -- Alberto Mardegan <alberto.mardegan@canonical.com> Tue, 09 Dec 2014 11:21:44 +0200
8
9libsignon-glib (1.10daily13.06.25-0ubuntu2) trusty; urgency=medium
10
11 * Rebuild to drop files installed into /usr/share/pyshared.
12
13 -- Matthias Klose <doko@ubuntu.com> Sun, 23 Feb 2014 13:48:19 +0000
14
1libsignon-glib (1.10daily13.06.25-0ubuntu1) saucy; urgency=low15libsignon-glib (1.10daily13.06.25-0ubuntu1) saucy; urgency=low
216
3 [ Jeremy Bicha ]17 [ Jeremy Bicha ]
418
=== modified file 'libsignon-glib/signon-auth-service.c'
--- libsignon-glib/signon-auth-service.c 2012-11-29 12:00:52 +0000
+++ libsignon-glib/signon-auth-service.c 2014-12-09 13:40:34 +0000
@@ -176,7 +176,7 @@
176/**176/**
177 * SignonQueryMethodsCb:177 * SignonQueryMethodsCb:
178 * @auth_service: the #SignonAuthService.178 * @auth_service: the #SignonAuthService.
179 * @methods: (transfer full) (type GStrv): list of available methods.179 * @methods: (transfer none) (type GStrv): list of available methods.
180 * @error: a #GError if an error occurred, %NULL otherwise.180 * @error: a #GError if an error occurred, %NULL otherwise.
181 * @user_data: the user data that was passed when installing this callback.181 * @user_data: the user data that was passed when installing this callback.
182 *182 *
@@ -218,7 +218,7 @@
218 * SignonQueryMechanismCb:218 * SignonQueryMechanismCb:
219 * @auth_service: the #SignonAuthService.219 * @auth_service: the #SignonAuthService.
220 * @method: the authentication method being inspected.220 * @method: the authentication method being inspected.
221 * @mechanisms: (transfer full) (type GStrv): list of available mechanisms.221 * @mechanisms: (transfer none) (type GStrv): list of available mechanisms.
222 * @error: a #GError if an error occurred, %NULL otherwise.222 * @error: a #GError if an error occurred, %NULL otherwise.
223 * @user_data: the user data that was passed when installing this callback.223 * @user_data: the user data that was passed when installing this callback.
224 *224 *
225225
=== modified file 'libsignon-glib/signon-auth-session.c'
--- libsignon-glib/signon-auth-session.c 2013-02-05 14:23:39 +0000
+++ libsignon-glib/signon-auth-session.c 2014-12-09 13:40:34 +0000
@@ -244,13 +244,25 @@
244 if (reply != NULL)244 if (reply != NULL)
245 g_hash_table_unref (reply);245 g_hash_table_unref (reply);
246 }246 }
247 g_variant_unref (v_reply);247
248 if (v_reply != NULL)
249 g_variant_unref (v_reply);
248250
249 g_slice_free (AuthSessionProcessCbData, cb_data);251 g_slice_free (AuthSessionProcessCbData, cb_data);
250 g_clear_error (&error);252 g_clear_error (&error);
251 g_object_unref (res);253 g_object_unref (res);
252}254}
253255
256static void
257destroy_proxy (SignonAuthSessionPrivate *priv)
258{
259 g_signal_handler_disconnect (priv->proxy, priv->signal_state_changed);
260 g_signal_handler_disconnect (priv->proxy, priv->signal_unregistered);
261 g_object_unref (priv->proxy);
262
263 priv->proxy = NULL;
264}
265
254static GQuark266static GQuark
255auth_session_object_quark ()267auth_session_object_quark ()
256{268{
@@ -288,13 +300,7 @@
288 }300 }
289301
290 if (priv->proxy)302 if (priv->proxy)
291 {303 destroy_proxy (priv);
292 g_signal_handler_disconnect (priv->proxy, priv->signal_state_changed);
293 g_signal_handler_disconnect (priv->proxy, priv->signal_unregistered);
294 g_object_unref (priv->proxy);
295
296 priv->proxy = NULL;
297 }
298304
299 if (priv->auth_service_proxy)305 if (priv->auth_service_proxy)
300 {306 {
@@ -503,7 +509,7 @@
503/**509/**
504 * SignonAuthSessionProcessCb:510 * SignonAuthSessionProcessCb:
505 * @self: the #SignonAuthSession.511 * @self: the #SignonAuthSession.
506 * @session_data: (transfer full) (element-type utf8 GValue): a dictionary with512 * @session_data: (transfer none) (element-type utf8 GValue): a dictionary with
507 * the response.513 * the response.
508 * @error: a #GError if an error occurred, %NULL otherwise.514 * @error: a #GError if an error occurred, %NULL otherwise.
509 * @user_data: the user data that was passed when installing this callback.515 * @user_data: the user data that was passed when installing this callback.
@@ -763,19 +769,8 @@
763 DEBUG ("remote object unregistered");769 DEBUG ("remote object unregistered");
764770
765 if (priv->proxy)771 if (priv->proxy)
766 {772 destroy_proxy (priv);
767 g_object_unref (priv->proxy);
768 priv->proxy = NULL;
769 }
770773
771 /*
772 * as remote object is destroyed only
773 * when the session core is destroyed,
774 * so there should not be any processes
775 * running
776 * */
777 priv->busy = FALSE;
778 priv->canceled = FALSE;
779 _signon_object_not_ready(self);774 _signon_object_not_ready(self);
780}775}
781776
782777
=== modified file 'libsignon-glib/signon-identity.h'
--- libsignon-glib/signon-identity.h 2012-01-27 10:24:27 +0000
+++ libsignon-glib/signon-identity.h 2014-12-09 13:40:34 +0000
@@ -165,7 +165,7 @@
165/**165/**
166 * SignonIdentityInfoCb:166 * SignonIdentityInfoCb:
167 * @self: the #SignonIdentity.167 * @self: the #SignonIdentity.
168 * @info: the #SignonIdentityInfo for @self.168 * @info: (transfer none): the #SignonIdentityInfo for @self.
169 * @error: a #GError if an error occurred, or %NULL otherwise.169 * @error: a #GError if an error occurred, or %NULL otherwise.
170 * @user_data: the user data that was passed when installing this callback.170 * @user_data: the user data that was passed when installing this callback.
171 *171 *
172172
=== modified file 'libsignon-glib/signon.vapi'
--- libsignon-glib/signon.vapi 2012-07-16 12:29:34 +0000
+++ libsignon-glib/signon.vapi 2014-12-09 13:40:34 +0000
@@ -6,8 +6,8 @@
6 public class AuthService : GLib.Object {6 public class AuthService : GLib.Object {
7 [CCode (has_construct_function = false)]7 [CCode (has_construct_function = false)]
8 public AuthService ();8 public AuthService ();
9 public void query_mechanisms (string method, Signon.QueryMechanismCb cb);9 public void query_mechanisms (string method, [CCode (scope = "async")] owned Signon.QueryMechanismCb cb);
10 public void query_methods (Signon.QueryMethodsCb cb);10 public void query_methods ([CCode (scope = "async")] owned Signon.QueryMethodsCb cb);
11 }11 }
12 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", type_id = "signon_auth_session_get_type ()")]12 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", type_id = "signon_auth_session_get_type ()")]
13 public class AuthSession : GLib.Object {13 public class AuthSession : GLib.Object {
@@ -15,9 +15,11 @@
15 public AuthSession (uint id, string method_name) throws GLib.Error;15 public AuthSession (uint id, string method_name) throws GLib.Error;
16 public void cancel ();16 public void cancel ();
17 public unowned string get_method ();17 public unowned string get_method ();
18 public void process (GLib.HashTable<string,GLib.Value?> session_data, string mechanism, Signon.AuthSessionProcessCb cb);18 [Deprecated (since = "1.8")]
19 public void query_available_mechanisms (string wanted_mechanisms, Signon.AuthSessionQueryAvailableMechanismsCb cb);19 public void process (GLib.HashTable<string,GLib.Value?> session_data, string mechanism, [CCode (scope = "async")] owned Signon.AuthSessionProcessCb cb);
20 public signal void state_changed (int object, string p0);20 public async GLib.Variant process_async (GLib.Variant session_data, string mechanism, GLib.Cancellable? cancellable) throws GLib.Error;
21 public void query_available_mechanisms (string wanted_mechanisms, [CCode (scope = "async")] owned Signon.AuthSessionQueryAvailableMechanismsCb cb);
22 public signal void state_changed (int state, string message);
21 }23 }
22 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", type_id = "signon_identity_get_type ()")]24 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", type_id = "signon_identity_get_type ()")]
23 public class Identity : GLib.Object {25 public class Identity : GLib.Object {
@@ -28,12 +30,12 @@
28 [CCode (has_construct_function = false)]30 [CCode (has_construct_function = false)]
29 public Identity.from_db (uint32 id);31 public Identity.from_db (uint32 id);
30 public unowned GLib.Error get_last_error ();32 public unowned GLib.Error get_last_error ();
31 public void query_info (Signon.IdentityInfoCb cb);33 public void query_info ([CCode (scope = "async")] owned Signon.IdentityInfoCb cb);
32 public void remove (Signon.IdentityRemovedCb cb, void* user_data);34 public void remove ([CCode (scope = "async")] owned Signon.IdentityRemovedCb cb, void* user_data);
33 public void remove_reference (string reference, Signon.IdentityReferenceRemovedCb cb, void* user_data);35 public void remove_reference (string reference, Signon.IdentityReferenceRemovedCb cb, void* user_data);
34 public void store_credentials_with_args (string username, string secret, bool store_secret, GLib.HashTable<string,string[]> methods, string caption, string realms, string access_control_list, Signon.IdentityType type, Signon.IdentityStoreCredentialsCb cb);36 public void store_credentials_with_args (string username, string secret, bool store_secret, GLib.HashTable<string,string[]> methods, string caption, string realms, string access_control_list, Signon.IdentityType type, [CCode (scope = "async")] owned Signon.IdentityStoreCredentialsCb cb);
35 public void store_credentials_with_info (Signon.IdentityInfo info, Signon.IdentityStoreCredentialsCb cb);37 public void store_credentials_with_info (Signon.IdentityInfo info, [CCode (scope = "async")] owned Signon.IdentityStoreCredentialsCb cb);
36 public void verify_secret (string secret, Signon.IdentityVerifyCb cb);38 public void verify_secret (string secret, [CCode (scope = "async")] owned Signon.IdentityVerifyCb cb);
37 [NoAccessorMethod]39 [NoAccessorMethod]
38 public uint id { get; set; }40 public uint id { get; set; }
39 [HasEmitter]41 [HasEmitter]
@@ -65,7 +67,7 @@
65 public void set_secret (string secret, bool store_secret);67 public void set_secret (string secret, bool store_secret);
66 public void set_username (string username);68 public void set_username (string username);
67 }69 }
68 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", cprefix = "SIGNON_IDENTITY_TYPE_")]70 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", cprefix = "SIGNON_IDENTITY_TYPE_", type_id = "signon_identity_type_get_type ()")]
69 [Flags]71 [Flags]
70 public enum IdentityType {72 public enum IdentityType {
71 OTHER,73 OTHER,
@@ -73,7 +75,7 @@
73 WEB,75 WEB,
74 NETWORK76 NETWORK
75 }77 }
76 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", cprefix = "SIGNON_POLICY_")]78 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", cprefix = "SIGNON_POLICY_", type_id = "signon_session_data_ui_policy_get_type ()")]
77 public enum SessionDataUiPolicy {79 public enum SessionDataUiPolicy {
78 DEFAULT,80 DEFAULT,
79 REQUEST_PASSWORD,81 REQUEST_PASSWORD,
@@ -120,7 +122,7 @@
120 public static GLib.Quark quark ();122 public static GLib.Quark quark ();
121 }123 }
122 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 3.9)]124 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 3.9)]
123 public delegate void AuthSessionProcessCb (Signon.AuthSession self, owned GLib.HashTable<string,GLib.Value?> session_data, GLib.Error error);125 public delegate void AuthSessionProcessCb (Signon.AuthSession self, GLib.HashTable<string,GLib.Value?> session_data, GLib.Error error);
124 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 3.9)]126 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 3.9)]
125 public delegate void AuthSessionQueryAvailableMechanismsCb (Signon.AuthSession self, [CCode (array_length = false, array_null_terminated = true)] owned string[] mechanisms, GLib.Error error);127 public delegate void AuthSessionQueryAvailableMechanismsCb (Signon.AuthSession self, [CCode (array_length = false, array_null_terminated = true)] owned string[] mechanisms, GLib.Error error);
126 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 3.9)]128 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 3.9)]
@@ -142,9 +144,9 @@
142 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 2.9)]144 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 2.9)]
143 public delegate void IdentityVoidCb (Signon.Identity self, GLib.Error error);145 public delegate void IdentityVoidCb (Signon.Identity self, GLib.Error error);
144 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 4.9)]146 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 4.9)]
145 public delegate void QueryMechanismCb (Signon.AuthService auth_service, string method, [CCode (array_length = false, array_null_terminated = true)] owned string[] mechanisms, GLib.Error error);147 public delegate void QueryMechanismCb (Signon.AuthService auth_service, string method, [CCode (array_length = false, array_null_terminated = true)] string[] mechanisms, GLib.Error error);
146 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 3.9)]148 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", instance_pos = 3.9)]
147 public delegate void QueryMethodsCb (Signon.AuthService auth_service, [CCode (array_length = false, array_null_terminated = true)] owned string[] methods, GLib.Error error);149 public delegate void QueryMethodsCb (Signon.AuthService auth_service, [CCode (array_length = false, array_null_terminated = true)] string[] methods, GLib.Error error);
148 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", cname = "SIGNON_SESSION_DATA_CAPTION")]150 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", cname = "SIGNON_SESSION_DATA_CAPTION")]
149 public const string SESSION_DATA_CAPTION;151 public const string SESSION_DATA_CAPTION;
150 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", cname = "SIGNON_SESSION_DATA_PROXY")]152 [CCode (cheader_filename = "libsignon-glib/signon-glib.h", cname = "SIGNON_SESSION_DATA_PROXY")]
151153
=== modified file 'tests/check_signon.c'
--- tests/check_signon.c 2013-06-05 07:34:33 +0000
+++ tests/check_signon.c 2014-12-09 13:40:34 +0000
@@ -648,6 +648,7 @@
648{648{
649 SignonIdentityInfo *info;649 SignonIdentityInfo *info;
650 SignonIdentity *identity;650 SignonIdentity *identity;
651 const gchar *const acl[] = { "*", NULL };
651652
652 g_debug("%s", G_STRFUNC);653 g_debug("%s", G_STRFUNC);
653654
@@ -659,6 +660,7 @@
659660
660 info = signon_identity_info_new ();661 info = signon_identity_info_new ();
661 signon_identity_info_set_username (info, "Nice user");662 signon_identity_info_set_username (info, "Nice user");
663 signon_identity_info_set_access_control_list (info, acl);
662664
663 signon_identity_store_credentials_with_info (identity,665 signon_identity_store_credentials_with_info (identity,
664 info,666 info,
@@ -716,6 +718,7 @@
716{718{
717 SignonIdentity *identity;719 SignonIdentity *identity;
718 GHashTable *methods;720 GHashTable *methods;
721 const gchar *const acl[] = { "*", NULL };
719 guint id = 0;722 guint id = 0;
720723
721 identity = signon_identity_new(NULL, NULL);724 identity = signon_identity_new(NULL, NULL);
@@ -728,7 +731,7 @@
728 methods,731 methods,
729 "caption",732 "caption",
730 NULL,733 NULL,
731 NULL,734 acl,
732 0,735 0,
733 new_identity_store_credentials_cb,736 new_identity_store_credentials_cb,
734 &id);737 &id);
@@ -788,7 +791,8 @@
788 fail_unless (error != NULL);791 fail_unless (error != NULL);
789792
790 fail_unless (error->domain == SIGNON_ERROR);793 fail_unless (error->domain == SIGNON_ERROR);
791 fail_unless (error->code == SIGNON_ERROR_IDENTITY_NOT_FOUND);794 fail_unless (error->code == SIGNON_ERROR_IDENTITY_NOT_FOUND ||
795 error->code == SIGNON_ERROR_PERMISSION_DENIED);
792796
793 end_test ();797 end_test ();
794}798}
@@ -880,6 +884,8 @@
880884
881START_TEST(test_verify_secret_identity)885START_TEST(test_verify_secret_identity)
882{886{
887 const gchar *const acl[] = { "*", NULL };
888
883 g_debug("%s", G_STRFUNC);889 g_debug("%s", G_STRFUNC);
884 SignonIdentity *idty = signon_identity_new(NULL, NULL);890 SignonIdentity *idty = signon_identity_new(NULL, NULL);
885 fail_unless (idty != NULL);891 fail_unless (idty != NULL);
@@ -899,7 +905,7 @@
899 methods,905 methods,
900 caption,906 caption,
901 NULL,907 NULL,
902 NULL,908 acl,
903 0,909 0,
904 store_credentials_identity_cb,910 store_credentials_identity_cb,
905 NULL);911 NULL);
@@ -1069,6 +1075,7 @@
10691075
1070static SignonIdentityInfo *create_standard_info()1076static SignonIdentityInfo *create_standard_info()
1071{1077{
1078 const gchar *const acl[] = { "*", NULL };
1072 g_debug("%s", G_STRFUNC);1079 g_debug("%s", G_STRFUNC);
1073 SignonIdentityInfo *info = signon_identity_info_new ();1080 SignonIdentityInfo *info = signon_identity_info_new ();
1074 signon_identity_info_set_username (info, "James Bond");1081 signon_identity_info_set_username (info, "James Bond");
@@ -1085,12 +1092,15 @@
1085 signon_identity_info_set_method (info, "method1", (const gchar **)mechanisms);1092 signon_identity_info_set_method (info, "method1", (const gchar **)mechanisms);
1086 signon_identity_info_set_method (info, "method2", (const gchar **)mechanisms);1093 signon_identity_info_set_method (info, "method2", (const gchar **)mechanisms);
1087 signon_identity_info_set_method (info, "method3", (const gchar **)mechanisms);1094 signon_identity_info_set_method (info, "method3", (const gchar **)mechanisms);
1095 signon_identity_info_set_access_control_list (info, acl);
10881096
1089 return info;1097 return info;
1090}1098}
10911099
1092START_TEST(test_info_identity)1100START_TEST(test_info_identity)
1093{1101{
1102 const gchar *const acl[] = { "*", NULL };
1103
1094 g_debug("%s", G_STRFUNC);1104 g_debug("%s", G_STRFUNC);
1095 SignonIdentity *idty = signon_identity_new();1105 SignonIdentity *idty = signon_identity_new();
1096 fail_unless (idty != NULL);1106 fail_unless (idty != NULL);
@@ -1114,7 +1124,7 @@
1114 methods,1124 methods,
1115 "caption",1125 "caption",
1116 NULL,1126 NULL,
1117 NULL,1127 acl,
1118 0,1128 0,
1119 store_credentials_identity_cb,1129 store_credentials_identity_cb,
1120 NULL);1130 NULL);

Subscribers

No one subscribed via source and target branches