[grilo-plugins] flickr: Fix variable leaking when response != 'ok'
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [grilo-plugins] flickr: Fix variable leaking when response != 'ok'
- Date: Thu, 29 Jun 2017 15:29:46 +0000 (UTC)
commit d9708fd5e3fc234e119f2ad33fb87c54c085882b
Author: Rafael Fonseca <r4f4rfs gmail com>
Date: Tue Jun 14 16:31:15 2016 +0200
flickr: Fix variable leaking when response != 'ok'
This variable was only being freed if the response was 'ok'.
https://bugzilla.gnome.org/show_bug.cgi?id=707643
src/flickr/gflickr.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/src/flickr/gflickr.c b/src/flickr/gflickr.c
index 09a8843..13f32e2 100644
--- a/src/flickr/gflickr.c
+++ b/src/flickr/gflickr.c
@@ -155,8 +155,10 @@ result_is_correct (xmlNodePtr node)
if (xmlStrcmp (node->name, (const xmlChar *) "rsp") == 0) {
stat = xmlGetProp (node, (const xmlChar *) "stat");
- if (stat && xmlStrcmp (stat, (const xmlChar *) "ok") == 0) {
- correct = TRUE;
+ if (stat) {
+ if (xmlStrcmp (stat, (const xmlChar *) "ok") == 0) {
+ correct = TRUE;
+ }
xmlFree (stat);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]