title: Warning: expected 'int (*)[3]' but argument is of type 'int **'
body: <p>I am calling an MPI function <code>MPI_Group_range_incl</code>. Here is its signature:</p>
  
  <pre><code>    int MPI_Group_range_incl(MPI_Group group, int n, int ranges[][3], 
                       MPI_Group *newgroup)
  </code></pre>
  
  <p>I am confused how to pass the <code>ranges[][3]</code> argument. Below is the code I have implemented. It compiles and works correctly but gives compile time warning: </p>
  
  <pre><code>warning: passing argument 3 of 'MPI_Group_range_incl' from incompatible pointer type [enabled by default]
  int errCode = MPI_Group_range_incl(existingGroup, n, (int**)nativeOneDimRanges, &amp;newGroup);
  
  mpi.h:989:5: note: expected 'int (*)[3]' but argument is of type 'int **'
  </code></pre>
  
  <p>How I call:</p>
  
  <pre><code>int oneDimRangesLen;
  jint *nativeOneDimRanges;
  jboolean isCopy = JNI_TRUE;
  MPI_Group newGroup;
  
  oneDimRangesLen = (*env)-&gt;GetArrayLength(env,oneDimRanges);
  nativeOneDimRanges = (*env)-&gt;GetIntArrayElements(env, oneDimRanges,
                                                   &amp;isCopy);
  
  
  MPI_Group existingGroup = (MPI_Group)
  ((*env)-&gt;GetLongField(env, thisObject ,GrouphandleID));
  
  int errCode = MPI_Group_range_incl(existingGroup, n, (int**)nativeOneDimRanges, &amp;newGroup);
  ...
  more code....
  ...
  </code></pre>
  
  <p>Note that </p>
  
  <pre><code>    jintArray oneDimRanges
  </code></pre>
  
  <p>comes as one dimensional int array from JVM but it actually contains the information needed by the function <code>MPI_Group_range_incl</code> with stride of 3. So it works fine, but I just want to get rid of the warnings. Any help?</p>