diff options
author | Luboš Luňák <l.lunak@collabora.com> | 2018-12-04 13:25:18 +0100 |
---|---|---|
committer | Luboš Luňák <l.lunak@collabora.com> | 2018-12-06 12:50:04 +0100 |
commit | d5b45b81ff621744de3d9b4598cf36d2a6657a8c (patch) | |
tree | 5da4cbacb4bea180e1d000ab3be2e62b46638724 /sc/source | |
parent | 168719432c10a87a86de4f494455c78844fdb81a (diff) |
OpenCL FVSCHEDULE() error checking
Change-Id: If93a9ea6e0265ba616b4a1fbe138d310ea3e8693
Reviewed-on: https://gerrit.libreoffice.org/64546
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
(cherry picked from commit 3156228b1d737ca47ff4e959a6e357581af3ec2e)
Reviewed-on: https://gerrit.libreoffice.org/64613
Diffstat (limited to 'sc/source')
-rw-r--r-- | sc/source/core/opencl/op_financial.cxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sc/source/core/opencl/op_financial.cxx b/sc/source/core/opencl/op_financial.cxx index 6f728cbbbdd2..66d1f9d18e28 100644 --- a/sc/source/core/opencl/op_financial.cxx +++ b/sc/source/core/opencl/op_financial.cxx @@ -750,8 +750,11 @@ void OpMDuration::GenSlidingWindowFunction(std::stringstream& ss, void Fvschedule::GenSlidingWindowFunction( std::stringstream &ss, const std::string &sSymName, SubArguments &vSubArguments) { + CHECK_PARAMETER_COUNT( 2, 2 ); FormulaToken* pCur = vSubArguments[1]->GetFormulaToken(); assert(pCur); + if(vSubArguments[0]->GetFormulaToken()->GetType() != formula::svDoubleVectorRef) + throw Unhandled( __FILE__, __LINE__ ); const formula::DoubleVectorRefToken* pCurDVR = static_cast<const formula::DoubleVectorRefToken *>(pCur); size_t nCurWindowSize = pCurDVR->GetRefRowSize(); |