We don't need a separate boolean variable
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
WERROR werror;
NTSTATUS status;
enum ndr_err_code ndr_err;
- bool found_tsig = false;
uint16_t i, arcount = 0;
DATA_BLOB tsig_blob, fake_tsig_blob, sig;
uint8_t *buffer = NULL;
/* Find the first TSIG record in the additional records */
for (i=0; i < packet->arcount; i++) {
if (packet->additional[i].rr_type == DNS_QTYPE_TSIG) {
- found_tsig = true;
break;
}
}
- if (!found_tsig) {
+ if (i == packet->arcount) {
+ /* no TSIG around */
return WERR_OK;
}