MB-12613: More clang static analyzer bug fixes

Change-Id: I7224aa79983eac281a5b11c482c73cdd74ef4515