[Webkit-unassigned] [Bug 12378] New: QString::mid is broken (KWQString.mm)

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jan 23 02:18:26 PST 2007


http://bugs.webkit.org/show_bug.cgi?id=12378

           Summary: QString::mid is broken (KWQString.mm)
           Product: WebKit
           Version: 418.x
          Platform: Macintosh
        OS/Version: Mac OS X 10.4
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: WebCore Misc.
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: freyther at handhelds.org


QString::mid from KWQ is broken. It refers to index which is not a class member
and not a global variable. index is the function from the C library. The
address of index is taken and compared to 0. As index is not declared as weak
symbol it is very unlikely that this comparsions leads to true.


The following code illustrates the issue:
cat method_test.mm
#include <stdio.h>
#include <stdlib.h>
#include <strings.h>

#include <unistd.h>


int main(int argc, char **argv) {
    if( fork == 0 && index == 0 )
        printf("Foo Bar\n");


    return EXIT_SUCCESS;
}

when compiling and executing nothing is printed on the terminal. I have not
searched for more occurences of the same pattern (taking an address of a
function and comparing it to a value).

Both WebKit418 and the Series60 port are affected


-- 
Configure bugmail: http://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list