title: Pointer targets in passing argument differ in signedness
body: <p>I've read through similar questions, but I've not been able to find one that helps me understand this warning in this case. I'm in my first week of trying to learn C, so apologies in advance. </p>
  
  <p>I get the following warning and note:</p>
  
  <pre><code>In function 'read_line':
  warning: pointer targets in passing argument 1 of 'read_byte' differ in signedness [-Wpointer-sign]
     res = read_byte(&amp;data);  
     ^
  note: expected 'char *' but argument is of type 'uint8_t *'
   char read_byte(char * data) 
  </code></pre>
  
  <p>When trying to compile this code:</p>
  
  <pre><code>#include &lt;stdlib.h&gt;
  #include &lt;stdio.h&gt;
  #include &lt;string.h&gt;
  #include &lt;stdint.h&gt;
  #include &lt;fcntl.h&gt;
  #include &lt;unistd.h&gt;
  
  char read_byte(char * data) 
  {
      if(fs &gt; 0 )
      {
          int n = read(fs, data, 1);
          if (n &lt; 0)
          {
              fprintf(stderr, "Read error\n");
              return 1;
          }
      }
      return *data;
  }
  
  uint8_t read_line(char * linebuf) 
  {
      uint8_t data, res;
      char * ptr = linebuf;
  
      do
      {
          res = read_byte(&amp;data);         
          if( res &lt; 0 )
          {
              fprintf(stderr, "res &lt; 0\n");
              break;
          }
  
          switch ( data )
          {
              case '\r' :
                  break;
              case '\n' : 
                  break;
              default : 
                  *(ptr++) = data;
                  break;
          }
  
      }while(data != '\n');
      *ptr = 0;               // terminaison
      return res;
  }
  
  int main(int argc, char **argv)
  {
      char buf[128];
  
      if( read_line(buf) == 10 )
      {
          // parse data
      }
  
      close(fs);
      return 0;
  }
  </code></pre>
  
  <p>I removed useless part including the one which opens the port and initializes fs.</p>