Files
qelectrotech-source-mirror/sources
Beat Hangartner e1acf95da4 Initialise the orientations of a default-constructed ConductorProfile
ConductorProfile's default constructor leaves beginOrientation and
endOrientation untouched, and the copy constructor and operator= then
read them from such a profile when a conductor's profiles are stored in
a QHash. UndefinedBehaviorSanitizer stops the binary there on every
project with conductors:

  conductorprofile.cpp:42:23: runtime error: load of value 1869263360,
  which is not a valid value for type 'Qet::Orientation'
    #0 ConductorProfile::ConductorProfile(ConductorProfile const&)
    #2 QHashPrivate::Node<Qt::Corner, ConductorProfile>::createInPlace

Give both members a default value, Qet::North, in the header. No
behaviour changes: a default-constructed profile is null (no segments)
and its orientations are never used before fromConductor() sets them.

No file-format change. Tests: the sanitizer build of the Linux CI job
(separate PR) fails on master with the report above and passes with
this change; all 23 example projects go through --export-svg and
--resave under ASan/UBSan on macOS without a report.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Signed-off-by: Beat Hangartner <beat@hangartners.ch>
2026-10-06 17:26:46 +02:00
..
2026-10-04 01:04:44 +02:00
2026-10-03 18:09:33 +02:00
2026-01-16 15:24:35 +01:00
2026-10-03 18:09:33 +02:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-10-03 18:09:33 +02:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-10-03 18:09:33 +02:00
2026-01-16 15:24:35 +01:00
2026-04-26 10:48:47 +02:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-08-08 08:09:45 +02:00
2026-08-06 21:37:40 +02:00
2026-08-06 21:37:40 +02:00
2026-01-16 15:24:35 +01:00
2026-09-18 18:28:48 +02:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-10-03 18:09:33 +02:00
2026-10-04 01:04:44 +02:00
2026-10-03 18:09:33 +02:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-07-17 10:29:13 +02:00
2026-07-17 10:29:13 +02:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00
2026-01-16 15:24:35 +01:00