Bug #55

Bug #247: Version 1.7 bugfixes

THaFormula containing parameters may crash

Added by Ole Hansen over 3 years ago. Updated over 2 years ago.

Status:NewStart date:
Priority:NormalDue date:
Assignee:Ole Hansen% Done:

0%

Category:-Estimated time:16.00 hours
Target version:1.7Spent time:-
Responsible:

Description

THaFormulas containing parameter expressions, or special functions that expect parameters, may crash. Examples:

f1 = new THaFormula("f1","gaus");
f1->Eval()
*** Break *** segmentation violation

double x = 1;
gHaVars->Define("x",x);
f2 = new THaFormula("f2","[0]+x")
f2->Eval()
*** Break *** segmentation violation

History

#1 Updated by Ole Hansen over 3 years ago

We already have a partial fix for this: Names of functions with parameters are blocked from being passed to TFormula. Instead, trying to create such a formula results in a syntax error now.

However, explicit parameters in a formula, e.g. "[0]", or parameterized functions from TFormulaPrimitive, e.g. "Pol1(0,0)", still cause a crash.

#2 Updated by Ole Hansen over 3 years ago

  • Start date deleted (11/22/2014)
  • Parent task set to #80

#3 Updated by Ole Hansen over 2 years ago

  • Parent task changed from #80 to #247

#4 Updated by Ole Hansen over 2 years ago

  • Target version changed from 1.6 to 1.7

Also available in: Atom PDF