In release mode, the Q_ASSERT() is a no-op, and Clang rightfully
pointed out that, in that case, the bool ok variable will be used
uninitialized.
Fix by using Q_UNREACHABLE(), which has an effect in both debug and
release builds.
Pick-to: 6.3 6.2 5.15
Change-Id: I33480aabe1c5233d1caddf9404f475ca9fcb8eaf
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>