added protection against empty strings in copy to avoid false warnings
authorkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 13 Apr 2012 16:36:58 +0000 (16:36 +0000)
committerkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 13 Apr 2012 16:36:58 +0000 (16:36 +0000)
ANALYSIS/AliESDtrackCuts.cxx

index db1922e..9792342 100644 (file)
@@ -542,16 +542,16 @@ void AliESDtrackCuts::Copy(TObject &c) const
   target.fCutMinDCAToVertexZ = fCutMinDCAToVertexZ;
 
   target.fCutMaxDCAToVertexXYPtDep = fCutMaxDCAToVertexXYPtDep;
-  target.SetMaxDCAToVertexXYPtDep(fCutMaxDCAToVertexXYPtDep.Data());
+  if(fCutMaxDCAToVertexXYPtDep.Length()>0)target.SetMaxDCAToVertexXYPtDep(fCutMaxDCAToVertexXYPtDep.Data());
 
   target.fCutMaxDCAToVertexZPtDep = fCutMaxDCAToVertexZPtDep;
-  target.SetMaxDCAToVertexZPtDep(fCutMaxDCAToVertexZPtDep.Data());
+  if(fCutMaxDCAToVertexZPtDep.Length()>0)target.SetMaxDCAToVertexZPtDep(fCutMaxDCAToVertexZPtDep.Data());
 
   target.fCutMinDCAToVertexXYPtDep = fCutMinDCAToVertexXYPtDep;
-  target.SetMinDCAToVertexXYPtDep(fCutMinDCAToVertexXYPtDep.Data());
+  if(fCutMinDCAToVertexXYPtDep.Length()>0)target.SetMinDCAToVertexXYPtDep(fCutMinDCAToVertexXYPtDep.Data());
 
   target.fCutMinDCAToVertexZPtDep = fCutMinDCAToVertexZPtDep;
-  target.SetMinDCAToVertexZPtDep(fCutMinDCAToVertexZPtDep.Data());
+  if(fCutMinDCAToVertexZPtDep.Length()>0)target.SetMinDCAToVertexZPtDep(fCutMinDCAToVertexZPtDep.Data());
 
   target.fPMin = fPMin;
   target.fPMax = fPMax;