<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>278790</bug_id>
          
          <creation_ts>2011-07-29 15:03:12 +0000</creation_ts>
          <short_desc>Telepathy chat handler places emoticons in URLs</short_desc>
          <delta_ts>2012-07-06 12:47:21 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>10</classification_id>
          <classification>Unmaintained</classification>
          <product>telepathy</product>
          <component>text-ui</component>
          <version>git-latest</version>
          <rep_platform>Gentoo Packages</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>NOR</priority>
          <bug_severity>minor</bug_severity>
          <target_milestone>0.4.0</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Geert Lamers">bugs.kde</reporter>
          <assigned_to name="Telepathy Bugs">kde-telepathy-bugs-null</assigned_to>
          <cc>kde</cc>
          
          <cf_commitlink></cf_commitlink>
          <cf_versionfixedin></cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1146929</commentid>
    <comment_count>0</comment_count>
      <attachid>62306</attachid>
    <who name="Geert Lamers">bugs.kde</who>
    <bug_when>2011-07-29 15:03:12 +0000</bug_when>
    <thetext>Created attachment 62306
Patch to fix wrongly parsed urls containing emoticons.

Version:           git-latest (using KDE 4.7.0) 
OS:                Linux

When a chat partner sends a URL, the chat handler replaces emoticons before the message is parsed for links. Any URL containing an emoticon is then no longer recognised as URL and thus not converted to link. In my case, the &apos;:/&apos; part of the protocol is replaced, rendering 90% of all links received unclickable.

Reproducible: Always

Steps to Reproduce:
Send (or receive) a URL containing a character sequence that is supposed to be replaced by an emoticon (for example, a URL prefixed with the protocol, where &apos;:/&apos; may be replaced by an emoticon (depends on emoticon theme)).

Actual Results:  
A funny face appears in the middle of the URL, link cannot be clicked.

Expected Results:  
No funny face, clickable link.

I&apos;ve added a patch that reverses the order (parse for links first, then for emoticons) that seems to fix it.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1148225</commentid>
    <comment_count>1</comment_count>
    <who name="David Edmundson">kde</who>
    <bug_when>2011-08-01 11:53:00 +0000</bug_when>
    <thetext>Patch looks good.

Do you have a KDE git account? If so, please merge it! 

Otherwise write back, and one of us will merge for you.

(sorry for the late reply)
Thanks a lot.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1148229</commentid>
    <comment_count>2</comment_count>
    <who name="Geert Lamers">bugs.kde</who>
    <bug_when>2011-08-01 12:06:10 +0000</bug_when>
    <thetext>I don&apos;t have a git account, go ahead and merge it.

Glad to help :)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1148577</commentid>
    <comment_count>3</comment_count>
    <who name="David Edmundson">kde</who>
    <bug_when>2011-08-01 23:45:16 +0000</bug_when>
    <thetext>Git commit d59d56ab545192fef0c0961fdc8d0760f86b99a0 by David Edmundson, on behalf of Geert Lamers.
Committed on 02/08/2011 at 01:44.
Pushed by davidedmundson into branch &apos;master&apos;.

Fix a bug in which emoticons can appear in URLs in messages, by swapping the order of processing

BUG: 278790

Reviewed by: David Edmundson

M  +6    -3    lib/adium-theme-view.cpp

http://commits.kde.org/telepathy-chat-handler/d59d56ab545192fef0c0961fdc8d0760f86b99a0</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1224167</commentid>
    <comment_count>4</comment_count>
    <who name="Geert Lamers">bugs.kde</who>
    <bug_when>2012-02-07 18:15:41 +0000</bug_when>
    <thetext>It seems this issue has reappeared.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1224182</commentid>
    <comment_count>5</comment_count>
    <who name="David Edmundson">kde</who>
    <bug_when>2012-02-07 18:56:26 +0000</bug_when>
    <thetext>Git commit ff89d55f6df486ad8ccf6c7a85e43dd2584b733c by David Edmundson.
Committed on 07/02/2012 at 19:54.
Pushed by davidedmundson into branch &apos;master&apos;.

Fix emoticons appearing in URLs (and breaking everything)

M  +1    -1    lib/message-processor.cpp

http://commits.kde.org/telepathy-text-ui/ff89d55f6df486ad8ccf6c7a85e43dd2584b733c</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1224184</commentid>
    <comment_count>6</comment_count>
    <who name="David Edmundson">kde</who>
    <bug_when>2012-02-07 18:57:37 +0000</bug_when>
    <thetext>We recently redid all the message processing, and in the process reversed some ordering.

That was really quickly spotted, thanks again!</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>62306</attachid>
            <date>2011-07-29 15:03:12 +0000</date>
            <delta_ts>2011-07-29 15:03:12 +0000</delta_ts>
            <desc>Patch to fix wrongly parsed urls containing emoticons.</desc>
            <filename>emoticons-in-url-fix.diff</filename>
            <type>text/plain</type>
            <size>1711</size>
            <attacher name="Geert Lamers">bugs.kde</attacher>
            
              <data encoding="base64">ZGlmZiAtLWdpdCBhL2xpYi9hZGl1bS10aGVtZS12aWV3LmNwcCBiL2xpYi9hZGl1bS10aGVtZS12
aWV3LmNwcAppbmRleCAwZWIxMDkwLi42ZDMwZDI3IDEwMDY0NAotLS0gYS9saWIvYWRpdW0tdGhl
bWUtdmlldy5jcHAKKysrIGIvbGliL2FkaXVtLXRoZW1lLXZpZXcuY3BwCkBAIC0zOTAsMTMgKzM5
MCwxMyBAQCBRU3RyaW5nIEFkaXVtVGhlbWVWaWV3OjpyZXBsYWNlU3RhdHVzS2V5d29yZHMoUVN0
cmluZyAmaHRtbFRlbXBsYXRlLCBjb25zdCBBZGl1bQogUVN0cmluZyBBZGl1bVRoZW1lVmlldzo6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VXJsICsgIic+IiArIHNob3duVXJsICsgIjwvYT4iOwotICAgICAgICAgICAgICAgIGh0
bWxUZW1wbGF0ZS5yZXBsYWNlKGluZGV4LCBzaG93blVybC5sZW5ndGgoKSwgbGluayk7CisgICAg
ICAgICAgICAgICAgbWVzc2FnZS5yZXBsYWNlKGluZGV4LCBzaG93blVybC5sZW5ndGgoKSwgbGlu
ayk7CiAgICAgICAgICAgICAgICAgLy8gYWR2YW5jZSBwb3NpdGlvbiBvdGhlcndpc2UgSSBlbmQg
dXAgcGFyc2luZyB0aGUgc2FtZSBsaW5rCiAgICAgICAgICAgICAgICAgaW5kZXggKz0gbGluay5s
ZW5ndGgoKTsKICAgICAgICAgICAgIH0gZWxzZSB7CkBAIC00NDEsNiArNDQxLDkgQEAgUVN0cmlu
ZyBBZGl1bVRoZW1lVmlldzo6cmVwbGFjZU1lc3NhZ2VLZXl3b3JkcyhRU3RyaW5nICZodG1sVGVt
cGxhdGUsIGNvbnN0IEFkaXUKICAgICAgICAgfQogICAgIH0KIAorICAgIG1lc3NhZ2UgPSBtX2Vt
b3RpY29ucy50aGVtZSgpLnBhcnNlRW1vdGljb25zKG1lc3NhZ2UpOworCWh0bWxUZW1wbGF0ZS5y
ZXBsYWNlKCIlbWVzc2FnZSUiLCBtZXNzYWdlKTsKKwogICAgIC8vc2VydmljZQogICAgIGh0bWxU
ZW1wbGF0ZS5yZXBsYWNlKCIlc2VydmljZSUiLCBpbmZvLnNlcnZpY2UoKSk7CiAgICAgLy90aW1l
Cg==
</data>

          </attachment>
      

    </bug>

</bugzilla>