Fixed #4846 (false positive: (warning) Comparison of a boolean with an integer.)