Core/Misc: Fix static analysis issues