From 79392043c4d2bff20c0dc549e75bff08a1f1aa62 Mon Sep 17 00:00:00 2001
From: Julien Malik <julien.malik@c-s.fr>
Date: Thu, 15 Dec 2011 15:18:52 +0100
Subject: [PATCH] BUG: wrong code around push_back

---
 Code/Simulation/otbSpectralResponse.txx | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Code/Simulation/otbSpectralResponse.txx b/Code/Simulation/otbSpectralResponse.txx
index 9307dde597..bc5cc02f98 100644
--- a/Code/Simulation/otbSpectralResponse.txx
+++ b/Code/Simulation/otbSpectralResponse.txx
@@ -241,9 +241,10 @@ typename SpectralResponse<TPrecision, TValuePrecision>::FilterFunctionValuesPoin
 
   //Assume that the SR is sorted
   typename FilterFunctionValuesType::ValuesVectorType valuesVector;
+  const Self& responseCalculator = *this;
   for (double i = m_Response.front()->first; i <= m_Response.back()->first; i += step)
     {
-    valuesVector.push_back = (*this)(i);
+    valuesVector.push_back( responseCalculator(i) );
     }
   FilterFunctionValuesPointerType functionValues = FilterFunctionValuesType::New();
 
-- 
GitLab