I'm dealing with this code written in c++:

```
int *V;
V = new int[nfilas*ncols];
iret=pthread_create(&threadList[i], NULL, worker_function, (void*)(&V)[nfilas*ncols]);

```

that passes "V" (a int array) to this function:

```
    int *matrix=(int*)ptr;
    for( int r=0; r<nfilas; ++r ){
    for( int c=0; c<ncols; c++ ){
        printf("%d ", matrix[r*ncols+c]);
    }

```

My problem is that i can't convert that void pointer into an array of int elements. How can i solve this? I've try many thing but I don't know what I'm doing wrong. Thank you in advance