title: incompatible types in assignment c
body: <p>I have following structs defined in my header file,</p>
  
  <pre><code>struct nl_packet {
        int seq;
        FRAMETYPE type;
        CnetAddr dest;
        CnetAddr src;
        uint32_t checksum;
        size_t length;
        char data[NL_MAXDATA];
      };
  
  
  struct seq_Info  {
  
     int seqNum;
     size_t length;
     char data[NL_MAXDATA];
  
  };
  
  struct msg_Received {
  
     CnetAddr src;
     struct seq_Info seqInfo[BUFSIZ];
     int lastReceived;
  
  };
  </code></pre>
  
  <p>and then in another file, I have the following assignment that comes with the "incompatible types in assignment error",</p>
  
  <pre><code>msgRec[i].seqInfo[j].data = packet.data;
  </code></pre>
  
  <p>I do have other statements like this in the same method but they work perfectly fine, </p>
  
  <pre><code>msgRec[i].seqInfo[j].seqNum = packet.seq;
  msgRec[i].seqInfo[j].length = packet.length;
  </code></pre>
  
  <p>Even though both, data fields in nl_packet struct and seq_Info struct have the same type, then is this error coming up ??</p>
  
  <p>Thanks in advance </p>