-R: some safety checks