Lines Matching refs:cp
432 if (cp + n > end) { \
438 static u_char *php_parserr(u_char *cp, u_char *end, querybuf *answer, int type_to_fetch, int store,… in php_parserr() argument
450 n = dn_expand(answer->qb2, end, cp, name, sizeof(name) - 2); in php_parserr()
454 cp += n; in php_parserr()
457 GETSHORT(type, cp); in php_parserr()
458 GETSHORT(class, cp); in php_parserr()
459 GETLONG(ttl, cp); in php_parserr()
460 GETSHORT(dlen, cp); in php_parserr()
467 cp += dlen; in php_parserr()
468 return cp; in php_parserr()
472 cp += dlen; in php_parserr()
473 return cp; in php_parserr()
485 add_assoc_stringl(subarray, "data", (char*) cp, (uint) dlen); in php_parserr()
486 cp += dlen; in php_parserr()
487 return cp; in php_parserr()
494 snprintf(name, sizeof(name), "%d.%d.%d.%d", cp[0], cp[1], cp[2], cp[3]); in php_parserr()
496 cp += dlen; in php_parserr()
501 GETSHORT(n, cp); in php_parserr()
518 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) - 2); in php_parserr()
522 cp += n; in php_parserr()
529 n = *cp & 0xFF; in php_parserr()
530 cp++; in php_parserr()
532 add_assoc_stringl(subarray, "cpu", (char*)cp, n); in php_parserr()
533 cp += n; in php_parserr()
535 n = *cp & 0xFF; in php_parserr()
536 cp++; in php_parserr()
538 add_assoc_stringl(subarray, "os", (char*)cp, n); in php_parserr()
539 cp += n; in php_parserr()
546 n = *cp & 0xFF; in php_parserr()
548 cp++; in php_parserr()
551 n = *cp & 0xFF; in php_parserr()
552 cp++; in php_parserr()
554 add_assoc_stringl(subarray, "tag", (char*)cp, n); in php_parserr()
555 cp += n; in php_parserr()
561 add_assoc_stringl(subarray, "value", (char*)cp, n); in php_parserr()
562 cp += n; in php_parserr()
576 n = cp[l1]; in php_parserr()
582 memcpy(ZSTR_VAL(tp) + l2 , cp + l1 + 1, n); in php_parserr()
583 add_next_index_stringl(&entries, (char *) cp + l1 + 1, n); in php_parserr()
590 cp += dlen; in php_parserr()
598 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) -2); in php_parserr()
602 cp += n; in php_parserr()
604 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) -2); in php_parserr()
608 cp += n; in php_parserr()
611 GETLONG(n, cp); in php_parserr()
613 GETLONG(n, cp); in php_parserr()
615 GETLONG(n, cp); in php_parserr()
617 GETLONG(n, cp); in php_parserr()
619 GETLONG(n, cp); in php_parserr()
626 GETSHORT(s, cp); in php_parserr()
657 p = cp; in php_parserr()
660 n = ((int)cp[0]) & 0xFF; in php_parserr()
661 cp++; in php_parserr()
672 if (cp[0] != 0) { in php_parserr()
678 sprintf((char*)tp, "%x", cp[0] & 0xFF); in php_parserr()
692 cp++; in php_parserr()
696 GETSHORT(s, cp); in php_parserr()
724 if (cp < p + dlen) { in php_parserr()
725 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) - 2); in php_parserr()
729 cp += n; in php_parserr()
736 GETSHORT(n, cp); in php_parserr()
738 GETSHORT(n, cp); in php_parserr()
740 GETSHORT(n, cp); in php_parserr()
742 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) - 2); in php_parserr()
746 cp += n; in php_parserr()
752 GETSHORT(n, cp); in php_parserr()
754 GETSHORT(n, cp); in php_parserr()
758 n = (cp[0] & 0xFF); in php_parserr()
759 cp++; in php_parserr()
761 add_assoc_stringl(subarray, "flags", (char*)cp, n); in php_parserr()
762 cp += n; in php_parserr()
765 n = (cp[0] & 0xFF); in php_parserr()
766 cp++; in php_parserr()
768 add_assoc_stringl(subarray, "services", (char*)cp, n); in php_parserr()
769 cp += n; in php_parserr()
772 n = (cp[0] & 0xFF); in php_parserr()
773 cp++; in php_parserr()
775 add_assoc_stringl(subarray, "regex", (char*)cp, n); in php_parserr()
776 cp += n; in php_parserr()
778 n = dn_expand(answer->qb2, end, cp, name, (sizeof name) - 2); in php_parserr()
782 cp += n; in php_parserr()
788 cp += dlen; in php_parserr()
792 return cp; in php_parserr()
815 u_char *cp = NULL, *end = NULL; in PHP_FUNCTION() local
967 cp = answer.qb2 + HFIXEDSZ; in PHP_FUNCTION()
977 n = dn_skipname(cp, end); in PHP_FUNCTION()
984 cp += n + QFIXEDSZ; in PHP_FUNCTION()
988 while (an-- && cp && cp < end) { in PHP_FUNCTION()
991 cp = php_parserr(cp, end, &answer, type_to_fetch, store_results, raw, &retval); in PHP_FUNCTION()
1001 while (ns-- > 0 && cp && cp < end) { in PHP_FUNCTION()
1004 cp = php_parserr(cp, end, &answer, DNS_T_ANY, authns != NULL, raw, &retval); in PHP_FUNCTION()
1013 while (ar-- > 0 && cp && cp < end) { in PHP_FUNCTION()
1016 cp = php_parserr(cp, end, &answer, DNS_T_ANY, 1, raw, &retval); in PHP_FUNCTION()
1040 u_char *cp, *end; in PHP_FUNCTION() local
1085 cp = (u_char *)&ans + HFIXEDSZ; in PHP_FUNCTION()
1087 for (qdc = ntohs((unsigned short)hp->qdcount); qdc--; cp += i + QFIXEDSZ) { in PHP_FUNCTION()
1088 if ((i = dn_skipname(cp, end)) < 0 ) { in PHP_FUNCTION()
1094 while (--count >= 0 && cp < end) { in PHP_FUNCTION()
1095 if ((i = dn_skipname(cp, end)) < 0 ) { in PHP_FUNCTION()
1099 cp += i; in PHP_FUNCTION()
1100 GETSHORT(type, cp); in PHP_FUNCTION()
1101 cp += INT16SZ + INT32SZ; in PHP_FUNCTION()
1102 GETSHORT(i, cp); in PHP_FUNCTION()
1104 cp += i; in PHP_FUNCTION()
1107 GETSHORT(weight, cp); in PHP_FUNCTION()
1108 if ((i = dn_expand(ans, end, cp, buf, sizeof(buf)-1)) < 0) { in PHP_FUNCTION()
1112 cp += i; in PHP_FUNCTION()