AIDASoft / DD4hep

Detector Description Toolkit for High Energy Physics
http://dd4hep.cern.ch
GNU Lesser General Public License v3.0
47 stars 93 forks source link

Fixed TwistedTube when only half-length is provided #1243

Closed atolosadelgado closed 4 months ago

atolosadelgado commented 4 months ago

It turns out that GetNegativeEndZ may be <0, leading to undefined behavior when the value is used as 'half-length' Replacing GetNegativeEndZ by GetPositiveEndZ in the Geant4 converting function fixes the problem because GetPositiveEndZ corresponds to the user value (that is expected to be the half-length of the twisted tube, as the half-length parameter of a regular tube)

The change is tested in my local installation of DD4hep.

BEGINRELEASENOTES

ENDRELEASENOTES

github-actions[bot] commented 4 months ago

Test Results

    7 files      7 suites   2h 53m 39s :stopwatch:   361 tests   353 :white_check_mark: 0 :zzz: 8 :x: 1 087 runs  1 079 :white_check_mark: 0 :zzz: 8 :x:

For more details on these failures, see this check.

Results for commit 182b432b.

:recycle: This comment has been updated with latest results.