Sophie

Sophie

distrib > Mandriva > 2009.0 > x86_64 > by-pkgid > e9de60276cedfc5ae7ca1246aa19d59c > files > 15

mozilla-thunderbird-2.0.0.19-0.2mdv2009.0.src.rpm

diff -p -up mozilla-thunderbird-2.0.0.14/mozilla/gfx/src/gtk/nsFontMetricsPango.cpp.335810 mozilla-thunderbird-2.0.0.14/mozilla/gfx/src/gtk/nsFontMetricsPango.cpp
--- mozilla-thunderbird-2.0.0.14/mozilla/gfx/src/gtk/nsFontMetricsPango.cpp.335810	2008-01-13 04:57:12.000000000 +0100
+++ mozilla-thunderbird-2.0.0.14/mozilla/gfx/src/gtk/nsFontMetricsPango.cpp	2008-06-28 17:10:12.000000000 +0200
@@ -952,7 +952,6 @@ nsFontMetricsPango::GetPosition(const PR
 {
     int trailing = 0;
     int inx = 0;
-    gboolean found = FALSE;
     const gchar *curChar;
     PRInt32 retval = 0;
 
@@ -978,22 +977,12 @@ nsFontMetricsPango::GetPosition(const PR
     pango_layout_set_text(layout, text, strlen(text));
     FixupSpaceWidths(layout, text);
     
-    found = pango_layout_xy_to_index(layout, localX, localY,
-                                     &inx, &trailing);
+    pango_layout_xy_to_index(layout, localX, localY,
+                             &inx, &trailing);
 
     // Convert the index back to the utf-16 index
     curChar = text;
 
-    // Jump to the end if it's not found.
-    if (!found) {
-        if (inx == 0)
-            retval = 0;
-        else if (trailing)
-            retval = aLength;
-
-        goto loser;
-    }
-
     for (PRUint32 curOffset=0; curOffset < aLength;
          curOffset++, curChar = g_utf8_find_next_char(curChar, NULL)) {