billiob pushed a commit to branch master.

http://git.enlightenment.org/apps/terminology.git/commit/?id=5d6544ed7689c9b7988d373502ff46f97220b080

commit 5d6544ed7689c9b7988d373502ff46f97220b080
Author: Boris Faure <bill...@gmail.com>
Date:   Wed Jun 3 23:04:03 2015 +0200

    do not update an url if Location is local
---
 src/bin/win.c | 19 +++++++++++--------
 1 file changed, 11 insertions(+), 8 deletions(-)

diff --git a/src/bin/win.c b/src/bin/win.c
index 941e954..6a99c6e 100644
--- a/src/bin/win.c
+++ b/src/bin/win.c
@@ -2933,16 +2933,19 @@ _media_http_head_complete(void *data, int kind 
EINA_UNUSED, void *event_info)
              unsigned int len;
 
              str += strlen(_LOCATION_HDR);
-             eina_stringshare_del(ty_head->src);
+             if (*str != '/')
+               {
+                  eina_stringshare_del(ty_head->src);
 
-             /* skip the crlf */
-             len = strlen(str);
-             if (len <= 2)
-               goto error;
+                  /* skip the crlf */
+                  len = strlen(str);
+                  if (len <= 2)
+                    goto error;
 
-             ty_head->src = eina_stringshare_add_length(str, len - 2);
-             if (!ty_head->src)
-               goto error;
+                  ty_head->src = eina_stringshare_add_length(str, len - 2);
+                  if (!ty_head->src)
+                    goto error;
+               }
           }
         else if (!strncmp(str, _CONTENT_TYPE_HDR, strlen(_CONTENT_TYPE_HDR)))
           {

-- 


Reply via email to