From 04a55306dab76d6f8bb51d8b1c6e8fd7b277b03c Mon Sep 17 00:00:00 2001 From: Rene Brun <Rene.Brun@cern.ch> Date: Thu, 30 Sep 2010 14:25:54 +0000 Subject: [PATCH] use snprintf git-svn-id: http://root.cern.ch/svn/root/trunk@35915 27541ba8-7e3a-0410-8455-c3a389f83636 --- montecarlo/eg/src/TPrimary.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/montecarlo/eg/src/TPrimary.cxx b/montecarlo/eg/src/TPrimary.cxx index 36b7ee3af1a..71fe82f9078 100644 --- a/montecarlo/eg/src/TPrimary.cxx +++ b/montecarlo/eg/src/TPrimary.cxx @@ -161,7 +161,7 @@ const char *TPrimary::GetTitle() const //return title of primary particle static char title[128]; Float_t pmom = TMath::Sqrt(fPx*fPx+fPy*fPy+fPz*fPz); - sprintf(title,"pmom=%f GeV",pmom); + snprintf(title,128,"pmom=%f GeV",pmom); return title; } -- GitLab