Fixes to policy handling.