https://bugs.freedesktop.org/show_bug.cgi?id=38592

Peter Ansell <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|3.3.2 release               |4.1.1.2 release

--- Comment #10 from Peter Ansell <[email protected]> ---
http://opengrok.libreoffice.org/xref/core/sc/source/filter/oox/formulaparser.cxx#384
:

void FormulaFinalizer::appendCalcOnlyParameter( const FunctionInfo& rFuncInfo,
size_t nParam )
{
    (void)nParam;   // prevent 'unused' warning
    switch( rFuncInfo.mnBiff12FuncId )
    {
        case BIFF_FUNC_FLOOR:
        case BIFF_FUNC_CEILING:
            OSL_ENSURE( nParam == 2, "FormulaFinalizer::appendCalcOnlyParameter
- unexpected parameter index" );
            maTokens.append< double >( OPCODE_PUSH, 1.0 );
            maTokens.append( OPCODE_SEP );
        break;
    }
}

I am not sure what OSL_ENSURE does, but if it doesn't fail at that line, it
looks like this function will add extra parameters to both CEILING and FLOOR
without strictly relying on nParam. Naively, it looks like there should be an
if(nParam == 2) {} wrapper instead of just OSL_ENSURE.

The bug tracking this issue for the FLOOR function is Bug 69072

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to