diff --git a/OREData/ored/marketdata/yieldcurve.cpp b/OREData/ored/marketdata/yieldcurve.cpp index 52164fdaf9..7c1303b316 100644 --- a/OREData/ored/marketdata/yieldcurve.cpp +++ b/OREData/ored/marketdata/yieldcurve.cpp @@ -280,10 +280,10 @@ YieldCurve::YieldCurve(Date asof, YieldCurveSpec curveSpec, const CurveConfigura buildBootstrappedCurve(); } - h_.linkTo(p_); if (extrapolation_) { - h_->enableExtrapolation(); + p_->enableExtrapolation(); } + h_.linkTo(p_); // populate shared calibration info diff --git a/OREData/ored/portfolio/fxdigitaloption.cpp b/OREData/ored/portfolio/fxdigitaloption.cpp index 7c7c821042..35f29648b0 100644 --- a/OREData/ored/portfolio/fxdigitaloption.cpp +++ b/OREData/ored/portfolio/fxdigitaloption.cpp @@ -51,6 +51,7 @@ void FxDigitalOption::build(const boost::shared_ptr& engineFactor bool flipResults = false; if (payoffCurrency_ == "") { DLOG("PayoffCurrency defaulting to " << domesticCurrency_ << " for FxDigitalOption " << id()); + payoffCurrency_ = domesticCurrency_; } else if (payoffCurrency_ == foreignCurrency_) { // Invert the trade, switch dom and for and flip Put/Call strike = 1.0 / strike;