title: Weird output after assign new char
body: <p><strong>This is my code [NOTE: not the full code, but only these cause problem]</strong></p>
  
  <pre><code>#define RNC 3
  int main(int argc, const char *argv[])
  {
  
      char *labyrinth[RNC + 2] = {
          "00000",
          "01100",
          "00101",
          "01111",
          "00101",
      };
  
      char *markedLabyrinth[RNC + 2] = {
          "00000",
          "00000",
          "00000",
          "00000",
          "00000",
      };
  
      printf("Test = %s\n", markedLabyrinth[1]);
      printf("Please specific where is the exit point Ex. [ 3 5 ] : ");
      scanf("%d %d", &amp;K, &amp;L);
  
      int i, row, column;
      markedLabyrinth[1] = (char *)malloc(sizeof(char) * 6);
      markedLabyrinth[1][2] = '1';
      printf("Test After = %s\n", markedLabyrinth[1]);
  }
  </code></pre>
  
  <p>.</p>
  
  <p><strong>And this is the output from my compiler</strong></p>
  
  <pre><code>Test = 00000
  Please specific where is the exit point Ex. [ 3 5 ] : 3 4 // this is my input, [ignore it ^^]
  Test After = @q1
  </code></pre>
  
  <p>and as you can see i tried to assign just the <strong>markLabyrinth[1][2] to = '1'</strong> and the output should be</p>
  
  <pre><code>Test After = 00100
  </code></pre>
  
  <p>but it gives me</p>
  
  <pre><code>Test After = @q1
  </code></pre>
  
  <p>Please take a look at this code for me please,<strong>Thank you</strong></p>