Lines Matching defs:descriptor
71 struct Descriptor { PRInt32 length; PRUint32 checksum; } descriptor;
134 iov[0].iov_base = (char*)&descriptor;
135 iov[0].iov_len = sizeof(descriptor);
160 descriptor.checksum = 0;
161 descriptor.length = (loop < (messages - 1)) ? message_length : 0;
162 if (0 == descriptor.length) number_fragments = 1;
164 for (iov_index = 0; iov_index < descriptor.length; ++iov_index)
166 PRUint32 overflow = descriptor.checksum & 0x80000000;
167 descriptor.checksum = (descriptor.checksum << 1);
168 if (0x00000000 != overflow) descriptor.checksum += 1;
169 descriptor.checksum += buffer[iov_index];
172 debug, "sending %d bytes ... ", descriptor.length);
175 descriptor.length = PR_ntohl(descriptor.length);
176 descriptor.checksum = PR_ntohl(descriptor.checksum);