Apache OpenOffice (AOO) Bugzilla – Issue 84277
Calc crashes if cell uses faulty macro for validation
Last modified: 2013-08-07 15:15:24 UTC
(Actually this was found on OOo 2.3.1 but can't seem to select that in the Bug Reporting tool yet) Calc crashes when using a macro containing errors to generate list of values. STEPS TO REPRODUCE THE PROBLEM 1. Open a new Calc spreadsheet, and define a macro with some errors in it such as: Sub SubContainingErrors ' Some random text that BASIC won't understand This Is Not Code End Sub 2. Select a cell, and goto Data -> Validity 3. In 'Allow', enter 'Cell Range'; and for 'Source', enter 'SubContainingErrors()'; also ensure that 'Show Selection List' is checked. 4. OK the Validity dialog. 5. Click on the dropdown for the cell. The BASIC Interpreter generates a few errors, then Calc informs the user of an unexpected crash. PROPOSED SOLUTION Instead of crashing, the BASIC Interpreter should just generate the runtime errors then allow the user to continue working on the spreadsheet / fix the macro.
Can't reproduce with 2.4m241 on WinXP. silvercapo, could you, please, attach sample doc with macro etc defined? Thanks.
Created attachment 50768 [details] Demonstrates the error
Attached a document demonstrating this - try to open the dropdown in the first cell A1, and Calc eventually crashes. Apologies - in my original STEPS TO REPRODUCE THE PROBLEM - the Sub in step (1) should be a Function
Confirming with 2.4m241 on WinXP - as described. Setting keyword, priority.
Hi Andreas, seems to be yours. Frank
ab->fst: It only seems... :-) ab->nn: The crash happens in calc, Basic isn't even on the stack any more (from src680 m239 wntmsci10.pro): > sc680mi.dll!ScGridWindow::DoAutoFilterMenue(short nCol=0, long nRow=0, unsigned char bDataSelect='') Line 963 + 0x6 bytes C++ sc680mi.dll!ScGridWindow::HandleMouseButtonDown(const MouseEvent & rMEvt={...}) Line 1671 C++ sc680mi.dll!ScGridWindow::MouseButtonDown(const MouseEvent & rMEvt={...}) Line 1375 C++ vcl680mi.dll!ImplHandleMouseEvent(Window * pWindow=0x06f32b28, unsigned short nSVEvent=1, unsigned char bMouseLeave=0, long nX=16777367, long nY=0, unsigned long nMsgTime=254241000, unsigned short nCode=1, unsigned short nMode=3) Line 882 C++ vcl680mi.dll!ImplHandleSalMouseButtonDown(Window * pWindow=0x06f32b28, SalMouseEvent * pEvent=0x00eafab4) Line 2107 + 0x2e bytes C++ vcl680mi.dll!ImplWindowFrameProc(Window * pWindow=0x06f32b28, SalFrame * __formal=0x06f32368, unsigned short nEvent=3, const void * pEvent=0x00eafab4) Line 2360 C++ vcl680mi.dll!SalFrame::CallCallback(unsigned short nEvent=3, const void * pEvent=0x00eafab4) Line 304 + 0x16 bytes C++ vcl680mi.dll!ImplHandleMouseMsg(HWND__ * hWnd=0x000f0824, unsigned int nMsg=513, unsigned int wParam=1, long lParam=0) Line 3445 C++ vcl680mi.dll!SalFrameWndProc(HWND__ * hWnd=0x000f0824, unsigned int nMsg=513, unsigned int wParam=1, long lParam=9896057, int & rDef=1) Line 5737 + 0xf bytes C++ vcl680mi.dll!SalFrameWndProcW(HWND__ * hWnd=0x000f0824, unsigned int nMsg=513, unsigned int wParam=1, long lParam=9896057) Line 6148 + 0x15 bytes C++ user32.dll!7739b6e3() Obviously the ScGridWindow* this = 0x000000ac is corrupt. Maybe there's a problem with deactivation / focus lost. Please have a look.
Fixed on CWS "dr62". Changed: gridwin.cxx 1.95.12.1.
Reassigning to QA for verification
verified in internal build cws_dr62
closed because fix available in builds OOO300_m1