title: casting char[][] to char** causes segfault?
body: <p>Ok my C is a bit rusty but I figured I'd make my next(small) project in C so I could polish back up on it and less than 20 lines in I already have a seg fault.</p>
  
  <p>This is my complete code:</p>
  
  <pre><code>#define ROWS 4
  #define COLS 4
  
  char main_map[ROWS][COLS+1]={
    "a.bb",
    "a.c.",
    "adc.",
    ".dc."};
  
   void print_map(char** map){
    int i;
    for(i=0;i&lt;ROWS;i++){
      puts(map[i]); //segfault here
    }
   }
  
  
  
  int main(){
    print_map(main_map); //if I comment out this line it will work.
    puts(main_map[3]);
    return 0;
  }
  </code></pre>
  
  <p>I am completely confused as to how this is causing a segfault. What is happening when casting from <code>[][]</code> to <code>**</code>!? That is the only warning I get. </p>
  
  <pre>
  rushhour.c:23:3: warning: passing argument 1 of ‘print_map’ from incompatible pointer type
  rushhour.c:13:7: note: expected ‘char **’ but argument is of type ‘char (*)[5]’
  </pre>
  
  <p>Are <code>[][]</code> and <code>**</code> really not compatible pointer types? They seem like they are just syntax to me. </p>