title: warning: pointer targets in passing argument 2 of ‘strcat’ differ in signedness
body: <p>Below is the simple code:</p>
  
  <pre><code>unsigned char buf[255];
  unsigned char msg[255];
  
  while((res = read (fd, buf, (sizeof buf)-1)) &gt; 0)
  {
     buf[res] = '\0';
     strcat(msg, buf);
     length += res;
     if(length &gt;= 10)
          break;
  }
  </code></pre>
  
  <p>This line <code>strcat(msg, buf);</code> gives below warning:</p>
  
  <pre><code>warning: pointer targets in passing argument 1 of ‘strcat’ differ in signedness
  </code></pre>
  
  <p>I have tried every solution found for the similar question but didnt helped much. Can anyone please help why this is giving error when both variable are of same signedness. How can I remove it. Thanks</p>
  
  <p>Edit:</p>
  
  <pre><code>unsigned const char *buf[255];
  unsigned char *msg[255];
  strcat(msg, buf);
  </code></pre>
  
  <p>Now it gives warning:</p>
  
  <pre><code>warning: passing argument 2 of ‘strcat’ from incompatible pointer type
  </code></pre>