coverity defects
[u/mrichter/AliRoot.git] / CORRFW / AliCFEventRecCuts.cxx
index 25daa4b..b0a43cf 100644 (file)
@@ -365,10 +365,10 @@ void AliCFEventRecCuts::SetHistogramBins(Int_t index, Int_t nbins, Double_t xmin
   
   // book QA histograms
 
-  Char_t str[256];
+  Char_t str[5];
   for (Int_t i=0; i<kNStepQA; i++) {
-    if (i==0) sprintf(str," ");
-    else sprintf(str,"_cut");
+    if (i==0) snprintf(str,5," ");
+    else snprintf(str,5,"_cut");
 
     fhQA[kNTracks][i]  = new  TH1F(Form("%s_NTracks%s",GetName(),str),                 "",501,-0.5,500.5);
     fhQA[kVtxPosX][i]  = new  TH1F(Form("%s_Vtx_Pos_X%s",GetName(),str),               "",100,-5.,5.);