A few NPE fixes. Also, more Intent filter optimizations.