Fixes for static analyzer