[Webkit-unassigned] [Bug 24626] New: REGRESSION: undo-iframe-location-change.html is failing on the buildbots

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Mar 16 13:20:48 PDT 2009


https://bugs.webkit.org/show_bug.cgi?id=24626

           Summary: REGRESSION: undo-iframe-location-change.html is failing
                    on the buildbots
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Macintosh
               URL: http://build.webkit.org/results/trunk-mac-ppc-
                    release/16864/editing/undo/undo-iframe-location-change-
                    diffs.txt
        OS/Version: Mac OS X 10.5
            Status: NEW
          Severity: Normal
          Priority: P1
         Component: New Bugs
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: eric at webkit.org
                CC: justin.garcia at apple.com, sam at webkit.org


http://build.webkit.org/results/trunk-mac-ppc-release/16864/editing/undo/undo-iframe-location-change-diffs.txt

I've debugged it a little.  It seems that 

bool WebEditorClient::canUndo() const
{
    return [[m_webView undoManager] canUndo];
}

is actually returning "true".

void WebEditorClient::clearUndoRedoOperations()
{
    if (m_haveUndoRedoOperations) {
        // workaround for <rdar://problem/4645507> NSUndoManager dies
        // with uncaught exception when undo items cleared while
        // groups are open
        NSUndoManager *undoManager = [m_webView undoManager];
        int groupingLevel = [undoManager groupingLevel];
        for (int i = 0; i < groupingLevel; ++i)
            [undoManager endUndoGrouping];

        [undoManager removeAllActionsWithTarget:m_undoTarget.get()];

        for (int i = 0; i < groupingLevel; ++i)
            [undoManager beginUndoGrouping];

        m_haveUndoRedoOperations = NO;
        ASSERT(![undoManager canUndo]); // I ADDED THIS, IT FAILS!
    }
}

Should be called from 

bool FrameLoader::closeURL()
{
    saveDocumentState();
    stopLoading(true);
    m_frame->editor()->clearUndoRedoOperations();
    return true;
}

which it is, correctly.  The problem is that [undoManager canUndo] is still
true after calling clearUndoRedoOperations().  The test expects it to be false.
 Maybe other things in the undo stack (non-editing related) are causing this
test to fail?

I could change the test to call execCommand("redo") a bunch before running? 
Maybe that would fix the test failure.


-- 
Configure bugmail: https://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