Fix 3 small memory leaks

2 jobs for master in 12 minutes and 51 seconds (queued for 62 minutes and 34 seconds)
Status Job ID Name Coverage
  Build
passed #75054
clang_format

00:01:22

passed #75053
linux kf5-qt5 qt5.12

00:11:29

45.0%