Bat: Clone the arrays passed as parameter to the user code (fix #272)