fixes static analyzer issues.