Some runtime fixes