After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 729865 - identity: fix another principal leak
identity: fix another principal leak
Status: RESOLVED FIXED
Product: gnome-online-accounts
Classification: Core
Component: Kerberos
unspecified
Other All
: Normal normal
: ---
Assigned To: GNOME Online Accounts maintainer(s)
GNOME Online Accounts maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2014-05-09 11:31 UTC by Ray Strode [halfline]
Modified: 2014-05-09 12:56 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
identity: fix another principal leak (2.31 KB, patch)
2014-05-09 11:31 UTC, Ray Strode [halfline]
needs-work Details | Review
identity: fix another principal leak (4.96 KB, patch)
2014-05-09 11:58 UTC, Ray Strode [halfline]
committed Details | Review

Description Ray Strode [halfline] 2014-05-09 11:31:36 UTC
Spotted by valgrind.
Comment 1 Ray Strode [halfline] 2014-05-09 11:31:37 UTC
Created attachment 276233 [details] [review]
identity: fix another principal leak
Comment 2 Debarshi Ray 2014-05-09 11:52:06 UTC
Review of attachment 276233 [details] [review]:

::: src/goaidentity/goakerberosidentity.c
@@ +278,3 @@
                error_message);
       krb5_free_error_message (self->priv->kerberos_context, error_message);
+      goto out;

We should initialize indentifier to NULL so that it still returns NULL in the error path.
Comment 3 Ray Strode [halfline] 2014-05-09 11:58:04 UTC
Created attachment 276238 [details] [review]
identity: fix another principal leak

Spotted by valgrind.
Comment 4 Debarshi Ray 2014-05-09 12:08:20 UTC
Review of attachment 276238 [details] [review]:

Yes, this looks fine. Thanks for the patch.
Comment 5 Ray Strode [halfline] 2014-05-09 12:19:43 UTC
Attachment 276238 [details] pushed as 9f4fff9 - identity: fix another principal leak
Comment 6 Debarshi Ray 2014-05-09 12:56:53 UTC
Cherry-picked to gnome-3-12 and gnome-3-10 (because latest Fedora is officially shipping GNOME 3.10.x)