Lines Matching refs:cp

440 	if (cp + n > end) { \
446 static uint8_t *php_parserr(uint8_t *cp, uint8_t *end, querybuf *answer, int type_to_fetch, int sto… in php_parserr() argument
458 n = dn_expand(answer->qb2, end, cp, name, sizeof(name) - 2); in php_parserr()
462 cp += n; in php_parserr()
465 GETSHORT(type, cp); in php_parserr()
466 GETSHORT(class, cp); in php_parserr()
467 GETLONG(ttl, cp); in php_parserr()
468 GETSHORT(dlen, cp); in php_parserr()
475 cp += dlen; in php_parserr()
476 return cp; in php_parserr()
480 cp += dlen; in php_parserr()
481 return cp; in php_parserr()
493 add_assoc_stringl(subarray, "data", (char*) cp, (uint32_t) dlen); in php_parserr()
494 cp += dlen; in php_parserr()
495 return cp; in php_parserr()
502 snprintf(name, sizeof(name), "%d.%d.%d.%d", cp[0], cp[1], cp[2], cp[3]); in php_parserr()
504 cp += dlen; in php_parserr()
509 GETSHORT(n, cp); in php_parserr()
526 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) - 2); in php_parserr()
530 cp += n; in php_parserr()
537 n = *cp & 0xFF; in php_parserr()
538 cp++; in php_parserr()
540 add_assoc_stringl(subarray, "cpu", (char*)cp, n); in php_parserr()
541 cp += n; in php_parserr()
543 n = *cp & 0xFF; in php_parserr()
544 cp++; in php_parserr()
546 add_assoc_stringl(subarray, "os", (char*)cp, n); in php_parserr()
547 cp += n; in php_parserr()
554 n = *cp & 0xFF; in php_parserr()
556 cp++; in php_parserr()
559 n = *cp & 0xFF; in php_parserr()
560 cp++; in php_parserr()
562 add_assoc_stringl(subarray, "tag", (char*)cp, n); in php_parserr()
563 cp += n; in php_parserr()
569 add_assoc_stringl(subarray, "value", (char*)cp, n); in php_parserr()
570 cp += n; in php_parserr()
584 n = cp[l1]; in php_parserr()
590 memcpy(ZSTR_VAL(tp) + l2 , cp + l1 + 1, n); in php_parserr()
591 add_next_index_stringl(&entries, (char *) cp + l1 + 1, n); in php_parserr()
598 cp += dlen; in php_parserr()
606 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) -2); in php_parserr()
610 cp += n; in php_parserr()
612 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) -2); in php_parserr()
616 cp += n; in php_parserr()
619 GETLONG(n, cp); in php_parserr()
621 GETLONG(n, cp); in php_parserr()
623 GETLONG(n, cp); in php_parserr()
625 GETLONG(n, cp); in php_parserr()
627 GETLONG(n, cp); in php_parserr()
634 GETSHORT(s, cp); in php_parserr()
665 p = cp; in php_parserr()
668 n = ((int)cp[0]) & 0xFF; in php_parserr()
669 cp++; in php_parserr()
680 if (cp[0] != 0) { in php_parserr()
686 sprintf((char*)tp, "%x", cp[0] & 0xFF); in php_parserr()
700 cp++; in php_parserr()
704 GETSHORT(s, cp); in php_parserr()
732 if (cp < p + dlen) { in php_parserr()
733 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) - 2); in php_parserr()
737 cp += n; in php_parserr()
744 GETSHORT(n, cp); in php_parserr()
746 GETSHORT(n, cp); in php_parserr()
748 GETSHORT(n, cp); in php_parserr()
750 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) - 2); in php_parserr()
754 cp += n; in php_parserr()
760 GETSHORT(n, cp); in php_parserr()
762 GETSHORT(n, cp); in php_parserr()
766 n = (cp[0] & 0xFF); in php_parserr()
767 cp++; in php_parserr()
769 add_assoc_stringl(subarray, "flags", (char*)cp, n); in php_parserr()
770 cp += n; in php_parserr()
773 n = (cp[0] & 0xFF); in php_parserr()
774 cp++; in php_parserr()
776 add_assoc_stringl(subarray, "services", (char*)cp, n); in php_parserr()
777 cp += n; in php_parserr()
780 n = (cp[0] & 0xFF); in php_parserr()
781 cp++; in php_parserr()
783 add_assoc_stringl(subarray, "regex", (char*)cp, n); in php_parserr()
784 cp += n; in php_parserr()
786 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) - 2); in php_parserr()
790 cp += n; in php_parserr()
796 cp += dlen; in php_parserr()
800 return cp; in php_parserr()
823 uint8_t *cp = NULL, *end = NULL; in PHP_FUNCTION() local
983 cp = answer.qb2 + HFIXEDSZ; in PHP_FUNCTION()
993 n = dn_skipname(cp, end); in PHP_FUNCTION()
1000 cp += n + QFIXEDSZ; in PHP_FUNCTION()
1004 while (an-- && cp && cp < end) { in PHP_FUNCTION()
1007 cp = php_parserr(cp, end, &answer, type_to_fetch, store_results, raw, &retval); in PHP_FUNCTION()
1017 while (ns-- > 0 && cp && cp < end) { in PHP_FUNCTION()
1020 cp = php_parserr(cp, end, &answer, DNS_T_ANY, authns != NULL, raw, &retval); in PHP_FUNCTION()
1029 while (ar-- > 0 && cp && cp < end) { in PHP_FUNCTION()
1032 cp = php_parserr(cp, end, &answer, DNS_T_ANY, 1, raw, &retval); in PHP_FUNCTION()
1055 uint8_t *cp, *end; in PHP_FUNCTION() local
1105 cp = answer.qb2 + HFIXEDSZ; in PHP_FUNCTION()
1107 for (qdc = ntohs((unsigned short)hp->qdcount); qdc--; cp += i + QFIXEDSZ) { in PHP_FUNCTION()
1108 if ((i = dn_skipname(cp, end)) < 0 ) { in PHP_FUNCTION()
1114 while (--count >= 0 && cp < end) { in PHP_FUNCTION()
1115 if ((i = dn_skipname(cp, end)) < 0 ) { in PHP_FUNCTION()
1119 cp += i; in PHP_FUNCTION()
1120 GETSHORT(type, cp); in PHP_FUNCTION()
1121 cp += INT16SZ + INT32SZ; in PHP_FUNCTION()
1122 GETSHORT(i, cp); in PHP_FUNCTION()
1124 cp += i; in PHP_FUNCTION()
1127 GETSHORT(weight, cp); in PHP_FUNCTION()
1128 if ((i = dn_expand(answer.qb2, end, cp, buf, sizeof(buf)-1)) < 0) { in PHP_FUNCTION()
1132 cp += i; in PHP_FUNCTION()