Index: modules/filter/filter.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/filter/filter.module,v
retrieving revision 1.250
diff -u -p -r1.250 filter.module
--- modules/filter/filter.module	14 May 2009 08:23:14 -0000	1.250
+++ modules/filter/filter.module	19 May 2009 15:51:37 -0000
@@ -820,7 +820,7 @@ function _filter_url_parse_full_links($m
   $match[2] = decode_entities($match[2]);
   $caption = check_plain(_filter_url_trim($match[2]));
   $match[2] = check_url($match[2]);
-  return $match[1] . '<a href="' . $match[2] . '" title="' . $match[2] . '">' . $caption . '</a>' . $match[5];
+  return $match[1] . '<a href="' . $match[2] . '" title="' . check_plain(urldecode($match[2])) . '">' . $caption . '</a>' . $match[5];
 }
 
 /**
@@ -830,7 +830,7 @@ function _filter_url_parse_partial_links
   $match[2] = decode_entities($match[2]);
   $caption = check_plain(_filter_url_trim($match[2]));
   $match[2] = check_plain($match[2]);
-  return $match[1] . '<a href="http://' . $match[2] . '" title="' . $match[2] . '">' . $caption . '</a>' . $match[3];
+  return $match[1] . '<a href="http://' . $match[2] . '" title="' . check_plain(urldecode($match[2])) . '">' . $caption . '</a>' . $match[3];
 }
 
 /**
@@ -842,6 +842,9 @@ function _filter_url_trim($text, $length
     $_length = $length;
   }
 
+  // Decode special characters.
+  $text = urldecode($text);
+
   // Use +3 for '...' string length.
   if (strlen($text) > $_length + 3) {
     $text = substr($text, 0, $_length) . '...';
