]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ANALYSIS/AliAnalysisAlien.cxx
Fix for savannah bug report 87728 (Laurent) + fix invalid read found with valgrind...
[u/mrichter/AliRoot.git] / ANALYSIS / AliAnalysisAlien.cxx
index 7269d40a6d654bb7165c7bc973c1bd686e9e985e..537ebbff144c23ab306ae0432cbe82e0ca02ce4e 100644 (file)
@@ -3793,9 +3793,15 @@ void AliAnalysisAlien::WriteAnalysisMacro()
             out << "   plugin->SetFileForTestMode(\"data.txt\");" << endl;
          else   
             out << "   plugin->SetFileForTestMode(\"" << fFileForTestMode << "\");" << endl;
+         out << "   plugin->SetNtestFiles(" << fNtestFiles << ");" << endl;
          out << "   mgr->SetGridHandler(plugin);" << endl;
-         out << "   mgr->SetDebugLevel(10);" << endl;
-         out << "   mgr->SetNSysInfo(100);" << endl;
+         if (AliAnalysisManager::GetAnalysisManager()) {
+            out << "   mgr->SetDebugLevel(" << AliAnalysisManager::GetAnalysisManager()->GetDebugLevel() << ");" << endl;
+            out << "   mgr->SetNSysInfo(" << AliAnalysisManager::GetAnalysisManager()->GetNsysInfo() << ");" << endl;
+         } else {
+            out << "   mgr->SetDebugLevel(10);" << endl;
+            out << "   mgr->SetNSysInfo(100);" << endl;
+         }
       }
       out << "   mgr->PrintStatus();" << endl;
       if (AliAnalysisManager::GetAnalysisManager()) {