Blame SOURCES/wget-1.19.5-covscan-important-issues.patch

62af7d
From b24351183ec574f81c729cbb3286aceaee3f03c8 Mon Sep 17 00:00:00 2001
62af7d
From: Tomas Hozza <thozza@redhat.com>
62af7d
Date: Mon, 30 Jul 2018 12:20:27 +0200
62af7d
Subject: [PATCH 1/6] * src/ftp.c (getftp): Fix RESOURCE LEAK found by Coverity
62af7d
62af7d
Error: RESOURCE_LEAK (CWE-772):
62af7d
wget-1.19.5/src/ftp.c:1493: alloc_fn: Storage is returned from allocation function "fopen".
62af7d
wget-1.19.5/src/ftp.c:1493: var_assign: Assigning: "fp" = storage returned from "fopen(con->target, "wb")".
62af7d
wget-1.19.5/src/ftp.c:1811: leaked_storage: Variable "fp" going out of scope leaks the storage it points to.
62af7d
\# 1809|     if (fp && !output_stream)
62af7d
\# 1810|       fclose (fp);
62af7d
\# 1811|->   return err;
62af7d
\# 1812|   }
62af7d
\# 1813|
62af7d
62af7d
It can happen, that "if (!output_stream || con->cmd & DO_LIST)" on line #1398 can be true, even though "output_stream != NULL". In this case a new file is opened to "fp". Later it may happen in the FTPS branch, that some error will occure and code will jump to label "exit_error". In "exit_error", the "fp" is closed only if "output_stream == NULL". However this may not be true as described earlier and "fp" leaks.
62af7d
62af7d
On line #1588, there is the following conditional free of "fp":
62af7d
62af7d
  /* Close the local file.  */
62af7d
  if (!output_stream || con->cmd & DO_LIST)
62af7d
    fclose (fp);
62af7d
62af7d
Therefore the conditional at the end of the function after "exit_error" label should be modified to:
62af7d
62af7d
  if (fp && (!output_stream || con->cmd & DO_LIST))
62af7d
    fclose (fp);
62af7d
62af7d
This will ensure that "fp" does not leak in any case it sould be opened.
62af7d
62af7d
Signed-off-by: Tomas Hozza <thozza@redhat.com>
62af7d
---
62af7d
 src/ftp.c | 2 +-
62af7d
 1 file changed, 1 insertion(+), 1 deletion(-)
62af7d
62af7d
diff --git a/src/ftp.c b/src/ftp.c
62af7d
index 69148936..daaae939 100644
62af7d
--- a/src/ftp.c
62af7d
+++ b/src/ftp.c
62af7d
@@ -1806,7 +1806,7 @@ Error in server response, closing control connection.\n"));
62af7d
 exit_error:
62af7d
 
62af7d
   /* If fp is a regular file, close and try to remove it */
62af7d
-  if (fp && !output_stream)
62af7d
+  if (fp && (!output_stream || con->cmd & DO_LIST))
62af7d
     fclose (fp);
62af7d
   return err;
62af7d
 }
62af7d
-- 
62af7d
2.17.1
62af7d
62af7d
62af7d
From b8be904ac7c25387672b0aa39f7cba699bffc48e Mon Sep 17 00:00:00 2001
62af7d
From: Tomas Hozza <thozza@redhat.com>
62af7d
Date: Mon, 30 Jul 2018 15:38:45 +0200
62af7d
Subject: [PATCH 2/6] * src/http.c (check_auth): Fix RESOURCE LEAK found by
62af7d
 Coverity
62af7d
62af7d
Error: RESOURCE_LEAK (CWE-772):
62af7d
wget-1.19.5/src/http.c:2434: alloc_fn: Storage is returned from allocation function "xmalloc".
62af7d
wget-1.19.5/lib/xmalloc.c:41:11: alloc_fn: Storage is returned from allocation function "malloc".
62af7d
wget-1.19.5/lib/xmalloc.c:41:11: var_assign: Assigning: "p" = "malloc(n)".
62af7d
wget-1.19.5/lib/xmalloc.c:44:3: return_alloc: Returning allocated memory "p".
62af7d
wget-1.19.5/src/http.c:2434: var_assign: Assigning: "auth_stat" = storage returned from "xmalloc(4UL)".
62af7d
wget-1.19.5/src/http.c:2446: noescape: Resource "auth_stat" is not freed or pointed-to in "create_authorization_line".
62af7d
wget-1.19.5/src/http.c:5203:70: noescape: "create_authorization_line(char const *, char const *, char const *, char const *, char const *, _Bool *, uerr_t *)" does not free or save its parameter "auth_err".
62af7d
wget-1.19.5/src/http.c:2476: leaked_storage: Variable "auth_stat" going out of scope leaks the storage it points to.
62af7d
\# 2474|                 /* Creating the Authorization header went wrong */
62af7d
\# 2475|               }
62af7d
\# 2476|->         }
62af7d
\# 2477|         else
62af7d
\# 2478|           {
62af7d
62af7d
Error: RESOURCE_LEAK (CWE-772):
62af7d
wget-1.19.5/src/http.c:2431: alloc_fn: Storage is returned from allocation function "url_full_path".
62af7d
wget-1.19.5/src/url.c:1105:19: alloc_fn: Storage is returned from allocation function "xmalloc".
62af7d
wget-1.19.5/lib/xmalloc.c:41:11: alloc_fn: Storage is returned from allocation function "malloc".
62af7d
wget-1.19.5/lib/xmalloc.c:41:11: var_assign: Assigning: "p" = "malloc(n)".
62af7d
wget-1.19.5/lib/xmalloc.c:44:3: return_alloc: Returning allocated memory "p".
62af7d
wget-1.19.5/src/url.c:1105:19: var_assign: Assigning: "full_path" = "xmalloc(length + 1)".
62af7d
wget-1.19.5/src/url.c:1107:3: noescape: Resource "full_path" is not freed or pointed-to in function "full_path_write".
62af7d
wget-1.19.5/src/url.c:1078:47: noescape: "full_path_write(struct url const *, char *)" does not free or save its parameter "where".
62af7d
wget-1.19.5/src/url.c:1110:3: return_alloc: Returning allocated memory "full_path".
62af7d
wget-1.19.5/src/http.c:2431: var_assign: Assigning: "pth" = storage returned from "url_full_path(u)".
62af7d
wget-1.19.5/src/http.c:2446: noescape: Resource "pth" is not freed or pointed-to in "create_authorization_line".
62af7d
wget-1.19.5/src/http.c:5203:40: noescape: "create_authorization_line(char const *, char const *, char const *, char const *, char const *, _Bool *, uerr_t *)" does not free or save its parameter "path".
62af7d
wget-1.19.5/src/http.c:2476: leaked_storage: Variable "pth" going out of scope leaks the storage it points to.
62af7d
\# 2474|                 /* Creating the Authorization header went wrong */
62af7d
\# 2475|               }
62af7d
\# 2476|->         }
62af7d
\# 2477|         else
62af7d
\# 2478|           {
62af7d
62af7d
Both "pth" and "auth_stat" are allocated in "check_auth()" function. These are used for creating the HTTP Authorization Request header via "create_authorization_line()" function. In case the creation went OK (auth_err == RETROK), then the memory previously allocated to "pth" and "auth_stat" is freed. However if the creation failed, then the memory is never freed and it leaks.
62af7d
62af7d
Signed-off-by: Tomas Hozza <thozza@redhat.com>
62af7d
---
62af7d
 src/http.c | 4 ++--
62af7d
 1 file changed, 2 insertions(+), 2 deletions(-)
62af7d
62af7d
diff --git a/src/http.c b/src/http.c
62af7d
index 093be167..4e0d467a 100644
62af7d
--- a/src/http.c
62af7d
+++ b/src/http.c
62af7d
@@ -2451,6 +2451,8 @@ check_auth (const struct url *u, char *user, char *passwd, struct response *resp
62af7d
                                               auth_stat);
62af7d
 
62af7d
           auth_err = *auth_stat;
62af7d
+          xfree (auth_stat);
62af7d
+          xfree (pth);
62af7d
           if (auth_err == RETROK)
62af7d
             {
62af7d
               request_set_header (req, "Authorization", value, rel_value);
62af7d
@@ -2464,8 +2466,6 @@ check_auth (const struct url *u, char *user, char *passwd, struct response *resp
62af7d
                   register_basic_auth_host (u->host);
62af7d
                 }
62af7d
 
62af7d
-              xfree (pth);
62af7d
-              xfree (auth_stat);
62af7d
               *retry = true;
62af7d
               goto cleanup;
62af7d
             }
62af7d
-- 
62af7d
2.17.1
62af7d
62af7d
62af7d
From dfef92bac3997b9848e86d84a843d5d7dde4fd99 Mon Sep 17 00:00:00 2001
62af7d
From: Tomas Hozza <thozza@redhat.com>
62af7d
Date: Tue, 31 Jul 2018 16:58:12 +0200
62af7d
Subject: [PATCH 3/6] * src/http.c (http_loop): Fix RESOURCE LEAK found by
62af7d
 Coverity
62af7d
62af7d
Error: RESOURCE_LEAK (CWE-772):
62af7d
wget-1.19.5/src/http.c:4486: alloc_fn: Storage is returned from allocation function "url_string".
62af7d
wget-1.19.5/src/url.c:2248:3: alloc_fn: Storage is returned from allocation function "xmalloc".
62af7d
wget-1.19.5/lib/xmalloc.c:41:11: alloc_fn: Storage is returned from allocation function "malloc".
62af7d
wget-1.19.5/lib/xmalloc.c:41:11: var_assign: Assigning: "p" = "malloc(n)".
62af7d
wget-1.19.5/lib/xmalloc.c:44:3: return_alloc: Returning allocated memory "p".
62af7d
wget-1.19.5/src/url.c:2248:3: var_assign: Assigning: "result" = "xmalloc(size)".
62af7d
wget-1.19.5/src/url.c:2248:3: var_assign: Assigning: "p" = "result".
62af7d
wget-1.19.5/src/url.c:2250:3: noescape: Resource "p" is not freed or pointed-to in function "memcpy". [Note: The source code implementation of the function has been overridden by a builtin model.]
62af7d
wget-1.19.5/src/url.c:2253:7: noescape: Resource "p" is not freed or pointed-to in function "memcpy". [Note: The source code implementation of the function has been overridden by a builtin model.]
62af7d
wget-1.19.5/src/url.c:2257:11: noescape: Resource "p" is not freed or pointed-to in function "memcpy". [Note: The source code implementation of the function has been overridden by a builtin model.]
62af7d
wget-1.19.5/src/url.c:2264:3: noescape: Resource "p" is not freed or pointed-to in function "memcpy". [Note: The source code implementation of the function has been overridden by a builtin model.]
62af7d
wget-1.19.5/src/url.c:2270:7: identity_transfer: Passing "p" as argument 1 to function "number_to_string", which returns an offset off that argument.
62af7d
wget-1.19.5/src/utils.c:1776:11: var_assign_parm: Assigning: "p" = "buffer".
62af7d
wget-1.19.5/src/utils.c:1847:3: return_var: Returning "p", which is a copy of a parameter.
62af7d
wget-1.19.5/src/url.c:2270:7: noescape: Resource "p" is not freed or pointed-to in function "number_to_string".
62af7d
wget-1.19.5/src/utils.c:1774:25: noescape: "number_to_string(char *, wgint)" does not free or save its parameter "buffer".
62af7d
wget-1.19.5/src/url.c:2270:7: var_assign: Assigning: "p" = "number_to_string(p, url->port)".
62af7d
wget-1.19.5/src/url.c:2273:3: noescape: Resource "p" is not freed or pointed-to in function "full_path_write".
62af7d
wget-1.19.5/src/url.c:1078:47: noescape: "full_path_write(struct url const *, char *)" does not free or save its parameter "where".
62af7d
wget-1.19.5/src/url.c:2287:3: return_alloc: Returning allocated memory "result".
62af7d
wget-1.19.5/src/http.c:4486: var_assign: Assigning: "hurl" = storage returned from "url_string(u, URL_AUTH_HIDE_PASSWD)".
62af7d
wget-1.19.5/src/http.c:4487: noescape: Resource "hurl" is not freed or pointed-to in "logprintf".
62af7d
wget-1.19.5/src/http.c:4513: leaked_storage: Variable "hurl" going out of scope leaks the storage it points to.
62af7d
\# 4511|               {
62af7d
\# 4512|                 printwhat (count, opt.ntry);
62af7d
\# 4513|->               continue;
62af7d
\# 4514|               }
62af7d
\# 4515|             else
62af7d
62af7d
There are two conditional branches, which call continue, without freeing memory potentially allocated and pointed to by"hurl" pointer. In fase "!opt.verbose" is True and some of the appropriate conditions in the following if/else if construction, in which "continue" is called, are also true, then the memory allocated to "hurl" will leak.
62af7d
62af7d
Signed-off-by: Tomas Hozza <thozza@redhat.com>
62af7d
---
62af7d
 src/http.c | 2 ++
62af7d
 1 file changed, 2 insertions(+)
62af7d
62af7d
diff --git a/src/http.c b/src/http.c
62af7d
index 4e0d467a..46fde6f2 100644
62af7d
--- a/src/http.c
62af7d
+++ b/src/http.c
62af7d
@@ -4492,6 +4492,7 @@ http_loop (const struct url *u, struct url *original_url, char **newloc,
62af7d
               && (hstat.statcode == 500 || hstat.statcode == 501))
62af7d
             {
62af7d
               got_head = true;
62af7d
+              xfree (hurl);
62af7d
               continue;
62af7d
             }
62af7d
           /* Maybe we should always keep track of broken links, not just in
62af7d
@@ -4510,6 +4511,7 @@ Remote file does not exist -- broken link!!!\n"));
62af7d
           else if (check_retry_on_http_error (hstat.statcode))
62af7d
             {
62af7d
               printwhat (count, opt.ntry);
62af7d
+              xfree (hurl);
62af7d
               continue;
62af7d
             }
62af7d
           else
62af7d
-- 
62af7d
2.17.1
62af7d
62af7d
62af7d
From c045cdded4e3850724d8bb3a655852948e62c0df Mon Sep 17 00:00:00 2001
62af7d
From: Tomas Hozza <thozza@redhat.com>
62af7d
Date: Thu, 2 Aug 2018 13:49:52 +0200
62af7d
Subject: [PATCH 4/6] * src/utils.c (open_stat): Fix RESOURCE LEAK found by
62af7d
 Coverity
62af7d
62af7d
Error: RESOURCE_LEAK (CWE-772):
62af7d
wget-1.19.5/src/utils.c:914: open_fn: Returning handle opened by "open". [Note: The source code implementation of the function has been overridden by a user model.]
62af7d
wget-1.19.5/src/utils.c:914: var_assign: Assigning: "fd" = handle returned from "open(fname, flags, mode)".
62af7d
wget-1.19.5/src/utils.c:921: noescape: Resource "fd" is not freed or pointed-to in "fstat". [Note: The source code implementation of the function has been overridden by a builtin model.]
62af7d
wget-1.19.5/src/utils.c:924: leaked_handle: Handle variable "fd" going out of scope leaks the handle.
62af7d
\#  922|     {
62af7d
\#  923|       logprintf (LOG_NOTQUIET, _("Failed to stat file %s, error: %s\n"), fname, strerror(errno));
62af7d
\#  924|->     return -1;
62af7d
\#  925|     }
62af7d
\#  926|   #if !(defined(WINDOWS) || defined(__VMS))
62af7d
62af7d
This seems to be a real issue, since the opened file descriptor in "fd"
62af7d
would leak. There is also additional check below the "fstat" call, which
62af7d
closes the opened "fd".
62af7d
62af7d
Signed-off-by: Tomas Hozza <thozza@redhat.com>
62af7d
---
62af7d
 src/utils.c | 1 +
62af7d
 1 file changed, 1 insertion(+)
62af7d
62af7d
diff --git a/src/utils.c b/src/utils.c
62af7d
index 0cb905ad..c6258083 100644
62af7d
--- a/src/utils.c
62af7d
+++ b/src/utils.c
62af7d
@@ -921,6 +921,7 @@ open_stat(const char *fname, int flags, mode_t mode, file_stats_t *fstats)
62af7d
   if (fstat (fd, &fdstats) == -1)
62af7d
   {
62af7d
     logprintf (LOG_NOTQUIET, _("Failed to stat file %s, error: %s\n"), fname, strerror(errno));
62af7d
+    close (fd);
62af7d
     return -1;
62af7d
   }
62af7d
 #if !(defined(WINDOWS) || defined(__VMS))
62af7d
-- 
62af7d
2.17.1
62af7d
62af7d
62af7d
From 8b451f9f21cc1b00d1a08116b542fb7bd7589405 Mon Sep 17 00:00:00 2001
62af7d
From: Tomas Hozza <thozza@redhat.com>
62af7d
Date: Fri, 3 Aug 2018 16:19:20 +0200
62af7d
Subject: [PATCH 5/6] * src/warc.c (warc_write_start_record): Fix potential
62af7d
 RESOURCE LEAK
62af7d
62af7d
In warc_write_start_record() function, the reutrn value of dup() is
62af7d
directly used in gzdopen() call and not stored anywhere. However the
62af7d
zlib documentation says that "The duplicated descriptor should be saved
62af7d
to avoid a leak, since gzdopen does not close fd if it fails." [1].
62af7d
This change stores the FD in a variable and closes it in case gzopen()
62af7d
fails.
62af7d
62af7d
[1] https://www.zlib.net/manual.html
62af7d
62af7d
Error: RESOURCE_LEAK (CWE-772):
62af7d
wget-1.19.5/src/warc.c:217: open_fn: Returning handle opened by "dup".
62af7d
wget-1.19.5/src/warc.c:217: leaked_handle: Failing to save or close handle opened by "dup(fileno(warc_current_file))" leaks it.
62af7d
\#  215|
62af7d
\#  216|         /* Start a new GZIP stream. */
62af7d
\#  217|->       warc_current_gzfile = gzdopen (dup (fileno (warc_current_file)), "wb9");
62af7d
\#  218|         warc_current_gzfile_uncompressed_size = 0;
62af7d
\#  219|
62af7d
62af7d
Signed-off-by: Tomas Hozza <thozza@redhat.com>
62af7d
---
62af7d
 src/warc.c | 13 ++++++++++++-
62af7d
 1 file changed, 12 insertions(+), 1 deletion(-)
62af7d
62af7d
diff --git a/src/warc.c b/src/warc.c
62af7d
index 3482cf3b..5ebd04d7 100644
62af7d
--- a/src/warc.c
62af7d
+++ b/src/warc.c
62af7d
@@ -203,6 +203,7 @@ warc_write_start_record (void)
62af7d
   /* Start a GZIP stream, if required. */
62af7d
   if (opt.warc_compression_enabled)
62af7d
     {
62af7d
+      int dup_fd;
62af7d
       /* Record the starting offset of the new record. */
62af7d
       warc_current_gzfile_offset = ftello (warc_current_file);
62af7d
 
62af7d
@@ -214,13 +215,23 @@ warc_write_start_record (void)
62af7d
       fflush (warc_current_file);
62af7d
 
62af7d
       /* Start a new GZIP stream. */
62af7d
-      warc_current_gzfile = gzdopen (dup (fileno (warc_current_file)), "wb9");
62af7d
+      dup_fd = dup (fileno (warc_current_file));
62af7d
+      if (dup_fd < 0)
62af7d
+        {
62af7d
+          logprintf (LOG_NOTQUIET,
62af7d
+_("Error duplicating WARC file file descriptor.\n"));
62af7d
+          warc_write_ok = false;
62af7d
+          return false;
62af7d
+        }
62af7d
+
62af7d
+      warc_current_gzfile = gzdopen (dup_fd, "wb9");
62af7d
       warc_current_gzfile_uncompressed_size = 0;
62af7d
 
62af7d
       if (warc_current_gzfile == NULL)
62af7d
         {
62af7d
           logprintf (LOG_NOTQUIET,
62af7d
 _("Error opening GZIP stream to WARC file.\n"));
62af7d
+          close (dup_fd);
62af7d
           warc_write_ok = false;
62af7d
           return false;
62af7d
         }
62af7d
-- 
62af7d
2.17.1
62af7d
62af7d
62af7d
From 2f451dbf4e83c751f6bbba7ed26d90bf275fcbf7 Mon Sep 17 00:00:00 2001
62af7d
From: Tomas Hozza <thozza@redhat.com>
62af7d
Date: Fri, 24 Aug 2018 16:57:37 +0200
62af7d
Subject: [PATCH 6/6] * src/warc.c (warc_write_cdx_record): Fix RESOURCE LEAK
62af7d
 found by Coverity
62af7d
62af7d
Error: RESOURCE_LEAK (CWE-772): - REAL ERROR
62af7d
wget-1.19.5/src/warc.c:1376: alloc_fn: Storage is returned from allocation function "url_escape".
62af7d
wget-1.19.5/src/url.c:284:3: alloc_fn: Storage is returned from allocation function "url_escape_1".
62af7d
wget-1.19.5/src/url.c:255:3: alloc_fn: Storage is returned from allocation function "xmalloc".
62af7d
wget-1.19.5/lib/xmalloc.c:41:11: alloc_fn: Storage is returned from allocation function "malloc".
62af7d
wget-1.19.5/lib/xmalloc.c:41:11: var_assign: Assigning: "p" = "malloc(n)".
62af7d
wget-1.19.5/lib/xmalloc.c:44:3: return_alloc: Returning allocated memory "p".
62af7d
wget-1.19.5/src/url.c:255:3: var_assign: Assigning: "newstr" = "xmalloc(newlen + 1)".
62af7d
wget-1.19.5/src/url.c:258:3: var_assign: Assigning: "p2" = "newstr".
62af7d
wget-1.19.5/src/url.c:275:3: return_alloc: Returning allocated memory "newstr".
62af7d
wget-1.19.5/src/url.c:284:3: return_alloc_fn: Directly returning storage allocated by "url_escape_1".
62af7d
wget-1.19.5/src/warc.c:1376: var_assign: Assigning: "redirect_location" = storage returned from "url_escape(redirect_location)".
62af7d
wget-1.19.5/src/warc.c:1381: noescape: Resource "redirect_location" is not freed or pointed-to in "fprintf".
62af7d
wget-1.19.5/src/warc.c:1387: leaked_storage: Returning without freeing "redirect_location" leaks the storage that it points to.
62af7d
\# 1385|     fflush (warc_current_cdx_file);
62af7d
\# 1386|
62af7d
\# 1387|->   return true;
62af7d
\# 1388|   }
62af7d
\# 1389|
62af7d
62af7d
url_escape() really returns a newly allocated memory and it leaks when the warc_write_cdx_record() returns. The memory returned from url_escape() is usually stored in a temporary variable in other parts of the project and then freed. I took the same approach.
62af7d
62af7d
Signed-off-by: Tomas Hozza <thozza@redhat.com>
62af7d
---
62af7d
 src/warc.c | 8 +++++---
62af7d
 1 file changed, 5 insertions(+), 3 deletions(-)
62af7d
62af7d
diff --git a/src/warc.c b/src/warc.c
62af7d
index 5ebd04d7..2eb74966 100644
62af7d
--- a/src/warc.c
62af7d
+++ b/src/warc.c
62af7d
@@ -1364,6 +1364,7 @@ warc_write_cdx_record (const char *url, const char *timestamp_str,
62af7d
   char timestamp_str_cdx[15];
62af7d
   char offset_string[MAX_INT_TO_STRING_LEN(off_t)];
62af7d
   const char *checksum;
62af7d
+  char *tmp_location = NULL;
62af7d
 
62af7d
   memcpy (timestamp_str_cdx     , timestamp_str     , 4); /* "YYYY" "-" */
62af7d
   memcpy (timestamp_str_cdx +  4, timestamp_str +  5, 2); /* "mm"   "-" */
62af7d
@@ -1382,18 +1383,19 @@ warc_write_cdx_record (const char *url, const char *timestamp_str,
62af7d
   if (mime_type == NULL || strlen(mime_type) == 0)
62af7d
     mime_type = "-";
62af7d
   if (redirect_location == NULL || strlen(redirect_location) == 0)
62af7d
-    redirect_location = "-";
62af7d
+    tmp_location = strdup ("-");
62af7d
   else
62af7d
-    redirect_location = url_escape(redirect_location);
62af7d
+    tmp_location = url_escape(redirect_location);
62af7d
 
62af7d
   number_to_string (offset_string, offset);
62af7d
 
62af7d
   /* Print the CDX line. */
62af7d
   fprintf (warc_current_cdx_file, "%s %s %s %s %d %s %s - %s %s %s\n", url,
62af7d
            timestamp_str_cdx, url, mime_type, response_code, checksum,
62af7d
-           redirect_location, offset_string, warc_current_filename,
62af7d
+           tmp_location, offset_string, warc_current_filename,
62af7d
            response_uuid);
62af7d
   fflush (warc_current_cdx_file);
62af7d
+  free (tmp_location);
62af7d
 
62af7d
   return true;
62af7d
 }
62af7d
-- 
62af7d
2.17.1
62af7d