Uploaded image for project: 'ROOT'
  1. ROOT
  2. ROOT-10882

Drawing crashes when histogram title contain special characters

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: master, 6.24/00, 6.20/08, 6.22/02
    • Component/s: None
    • Labels:
      None
    • Environment:

      ROOT Version: 6.18/04
      Built for linuxx8664gcc on Mar 24 2020, 15:18:00

      Description

      Drawing related segmentation violation occurs when trying to draw a histogram that contains special characters in the title.

      PyRoot code to reproduce the issue:

      from ROOT import TCanvas, TH1F
      canvas = TCanvas('c1', 'Example', 200, 10, 700, 500)
      histo = TH1F('name', 'phi_{Medium}_', 100, -4, 4)
      histo.Draw()
      canvas.Draw()

      'phi_{Medium}' is the issue in this case. If another character is appended to the end, for example: 'phi{Medium}_a', the code doesn't crash.

      The issue was observed in CMS DQM code: https://cmssdt.cern.ch/dxr/CMSSW/source/DQMOffline/Muon/src/MuonKinVsEtaAnalyzer.cc#109

      Regards,

      Andrius

        Attachments

          Activity

            People

            • Assignee:
              couet Olivier Couet
              Reporter:
              akirilov Andrius Kirilovas
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: