Lines Matching refs:header

38 …if (FAIL == mysqlnd_read_header((conn)->net, &((packet)->header), (conn)->stats, ((conn)->error_in…
45 if ((buf_size) < (packet)->header.size) { \
47 (buf_size), (packet)->header.size, (packet)->header.size - (buf_size)); \
50 …if (FAIL == conn->net->data->m.receive_ex((conn)->net, (buf), (packet)->header.size, (conn)->stats…
58 MYSQLND_HEADER_SIZE + (packet)->header.size, \
65 if ((size_t)(p - begin) > packet->header.size) { \
280 mysqlnd_read_header(MYSQLND_NET * net, MYSQLND_PACKET_HEADER * header, in mysqlnd_read_header() argument
291 header->size = uint3korr(buffer); in mysqlnd_read_header()
292 header->packet_no = uint1korr(buffer + 3); in mysqlnd_read_header()
295 DBG_INF_FMT("HEADER: prot_packet_no=%u size=%3u", header->packet_no, header->size); in mysqlnd_read_header()
301 if (net->data->compressed || net->packet_no == header->packet_no) { in mysqlnd_read_header()
312 net->packet_no, header->packet_no, header->size); in mysqlnd_read_header()
315 net->packet_no, header->packet_no, header->size); in mysqlnd_read_header()
339 if (packet->header.size < sizeof(buf)) { in php_mysqlnd_greet_read()
344 buf[packet->header.size] = '\0'; in php_mysqlnd_greet_read()
352 php_mysqlnd_read_error_from_line(p, packet->header.size - 1, in php_mysqlnd_greet_read()
400 if ((size_t) (p - buf) < packet->header.size) { in php_mysqlnd_greet_read()
410 if ((size_t) (p - buf) < packet->header.size) { in php_mysqlnd_greet_read()
449 DBG_ERR_FMT("GREET packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_greet_read()
451 p - begin - packet->header.size); in php_mysqlnd_greet_read()
475 mnd_pefree(p, p->header.persistent); in php_mysqlnd_greet_free_mem()
633 mnd_pefree(p, p->header.persistent); in php_mysqlnd_auth_free_mem()
664 buf[packet->header.size] = '\0'; in php_mysqlnd_auth_response_read()
672 php_mysqlnd_read_error_from_line(p, packet->header.size - 1, in php_mysqlnd_auth_response_read()
680 if (packet->header.size > (size_t) (p - buf)) { in php_mysqlnd_auth_response_read()
685 packet->new_auth_protocol_data_len = packet->header.size - (size_t) (p - buf); in php_mysqlnd_auth_response_read()
710 if (packet->header.size > (size_t) (p - buf) && (i = php_mysqlnd_net_field_length(&p))) { in php_mysqlnd_auth_response_read()
725 DBG_ERR_FMT("OK packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_auth_response_read()
727 p - begin - packet->header.size); in php_mysqlnd_auth_response_read()
755 mnd_pefree(p, p->header.persistent); in php_mysqlnd_auth_response_free_mem()
796 mnd_pefree(p, p->header.persistent); in php_mysqlnd_change_auth_response_free_mem()
827 php_mysqlnd_read_error_from_line(p, packet->header.size - 1, in php_mysqlnd_ok_read()
850 if (packet->header.size > (size_t) (p - buf) && (i = php_mysqlnd_net_field_length(&p))) { in php_mysqlnd_ok_read()
866 DBG_ERR_FMT("OK packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_ok_read()
868 p - begin - packet->header.size); in php_mysqlnd_ok_read()
884 mnd_pefree(p, p->header.persistent); in php_mysqlnd_ok_free_mem()
917 php_mysqlnd_read_error_from_line(p, packet->header.size - 1, in php_mysqlnd_eof_read()
929 if (packet->header.size > 1) { in php_mysqlnd_eof_read()
949 DBG_ERR_FMT("EOF packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_eof_read()
951 p - begin - packet->header.size); in php_mysqlnd_eof_read()
962 mnd_pefree(_packet, ((MYSQLND_PACKET_EOF *)_packet)->header.persistent); in php_mysqlnd_eof_free_mem()
1039 mnd_pefree(p, p->header.persistent); in php_mysqlnd_cmd_free_mem()
1070 php_mysqlnd_read_error_from_line(p, packet->header.size - 1, in php_mysqlnd_rset_header_read()
1091 len = packet->header.size - 1; in php_mysqlnd_rset_header_read()
1118 if (packet->header.size > (size_t) (p - buf) && (len = php_mysqlnd_net_field_length(&p))) { in php_mysqlnd_rset_header_read()
1142 DBG_ERR_FMT("RSET_HEADER packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_rset_header_read()
1144 p - begin - packet->header.size); in php_mysqlnd_rset_header_read()
1161 mnd_pefree(p, p->header.persistent); in php_mysqlnd_rset_header_free_mem()
1212 php_mysqlnd_read_error_from_line(p, packet->header.size - 1, in php_mysqlnd_rset_field_read()
1218 } else if (EODATA_MARKER == *p && packet->header.size < 8) { in php_mysqlnd_rset_field_read()
1294 if (packet->header.size > (size_t) (p - buf) && in php_mysqlnd_rset_field_read()
1373 DBG_ERR_FMT("RSET field packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_rset_field_read()
1375 "shorter than expected", p - begin - packet->header.size); in php_mysqlnd_rset_field_read()
1388 mnd_pefree(p, p->header.persistent); in php_mysqlnd_rset_field_free_mem()
1402 MYSQLND_PACKET_HEADER header; in php_mysqlnd_read_row_ex() local
1418 if (FAIL == mysqlnd_read_header(conn->net, &header, conn->stats, conn->error_info TSRMLS_CC)) { in php_mysqlnd_read_row_ex()
1423 *data_size += header.size; in php_mysqlnd_read_row_ex()
1439 if (!header.size) { in php_mysqlnd_read_row_ex()
1455 p = (*buffer)->ptr + (*data_size - header.size); in php_mysqlnd_read_row_ex()
1458 …if (PASS != (ret = conn->net->data->m.receive_ex(conn->net, p, header.size, conn->stats, conn->err… in php_mysqlnd_read_row_ex()
1464 if (header.size < MYSQLND_MAX_PACKET_SIZE) { in php_mysqlnd_read_row_ex()
1826 MYSQLND_HEADER_SIZE + packet->header.size, in php_mysqlnd_rowp_read()
1831 packet->header.size = data_size; in php_mysqlnd_rowp_read()
1906 DBG_INF_FMT("stack_allocation=%u persistent=%u", (int)stack_allocation, (int)p->header.persistent); in php_mysqlnd_rowp_free_mem()
1915 mnd_pefree(p, p->header.persistent); in php_mysqlnd_rowp_free_mem()
1934 packet->message = mnd_emalloc(packet->header.size + 1); in php_mysqlnd_stats_read()
1935 memcpy(packet->message, buf, packet->header.size); in php_mysqlnd_stats_read()
1936 packet->message[packet->header.size] = '\0'; in php_mysqlnd_stats_read()
1937 packet->message_len = packet->header.size; in php_mysqlnd_stats_read()
1954 mnd_pefree(p, p->header.persistent); in php_mysqlnd_stats_free_mem()
1981 data_size = packet->header.size; in php_mysqlnd_prepare_read()
2032 DBG_ERR_FMT("PREPARE packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_prepare_read()
2034 p - begin - packet->header.size); in php_mysqlnd_prepare_read()
2046 mnd_pefree(p, p->header.persistent); in php_mysqlnd_prepare_free_mem()
2077 …if (packet->header.size == 1 && buf[0] == EODATA_MARKER && packet->server_capabilities & CLIENT_SE… in php_mysqlnd_chg_user_read()
2084 php_mysqlnd_read_error_from_line(p, packet->header.size - 1, in php_mysqlnd_chg_user_read()
2092 if (packet->response_code == 0xFE && packet->header.size > (size_t) (p - buf)) { in php_mysqlnd_chg_user_read()
2096 packet->new_auth_protocol_data_len = packet->header.size - (size_t) (p - buf); in php_mysqlnd_chg_user_read()
2107 DBG_ERR_FMT("CHANGE_USER packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_chg_user_read()
2109 p - begin - packet->header.size); in php_mysqlnd_chg_user_read()
2134 mnd_pefree(p, p->header.persistent); in php_mysqlnd_chg_user_free_mem()
2163 mnd_pefree(p, p->header.persistent); in php_mysqlnd_sha256_pk_request_free_mem()
2189 packet->public_key_len = packet->header.size - (p - buf); in php_mysqlnd_sha256_pk_request_response_read()
2197 DBG_ERR_FMT("OK packet %d bytes shorter than expected", p - begin - packet->header.size); in php_mysqlnd_sha256_pk_request_response_read()
2199 p - begin - packet->header.size); in php_mysqlnd_sha256_pk_request_response_read()
2217 mnd_pefree(p, p->header.persistent); in php_mysqlnd_sha256_pk_request_response_free_mem()
2328 packet->header.m = &packet_methods[PROT_GREET_PACKET]; in MYSQLND_METHOD()
2329 packet->header.persistent = persistent; in MYSQLND_METHOD()
2343 packet->header.m = &packet_methods[PROT_AUTH_PACKET]; in MYSQLND_METHOD()
2344 packet->header.persistent = persistent; in MYSQLND_METHOD()
2358 packet->header.m = &packet_methods[PROT_AUTH_RESP_PACKET]; in MYSQLND_METHOD()
2359 packet->header.persistent = persistent; in MYSQLND_METHOD()
2373 packet->header.m = &packet_methods[PROT_CHANGE_AUTH_RESP_PACKET]; in MYSQLND_METHOD()
2374 packet->header.persistent = persistent; in MYSQLND_METHOD()
2388 packet->header.m = &packet_methods[PROT_OK_PACKET]; in MYSQLND_METHOD()
2389 packet->header.persistent = persistent; in MYSQLND_METHOD()
2403 packet->header.m = &packet_methods[PROT_EOF_PACKET]; in MYSQLND_METHOD()
2404 packet->header.persistent = persistent; in MYSQLND_METHOD()
2418 packet->header.m = &packet_methods[PROT_CMD_PACKET]; in MYSQLND_METHOD()
2419 packet->header.persistent = persistent; in MYSQLND_METHOD()
2433 packet->header.m = &packet_methods[PROT_RSET_HEADER_PACKET]; in MYSQLND_METHOD()
2434 packet->header.persistent = persistent; in MYSQLND_METHOD()
2448 packet->header.m = &packet_methods[PROT_RSET_FLD_PACKET]; in MYSQLND_METHOD()
2449 packet->header.persistent = persistent; in MYSQLND_METHOD()
2463 packet->header.m = &packet_methods[PROT_ROW_PACKET]; in MYSQLND_METHOD()
2464 packet->header.persistent = persistent; in MYSQLND_METHOD()
2478 packet->header.m = &packet_methods[PROT_STATS_PACKET]; in MYSQLND_METHOD()
2479 packet->header.persistent = persistent; in MYSQLND_METHOD()
2493 packet->header.m = &packet_methods[PROT_PREPARE_RESP_PACKET]; in MYSQLND_METHOD()
2494 packet->header.persistent = persistent; in MYSQLND_METHOD()
2508 packet->header.m = &packet_methods[PROT_CHG_USER_RESP_PACKET]; in MYSQLND_METHOD()
2509 packet->header.persistent = persistent; in MYSQLND_METHOD()
2523 packet->header.m = &packet_methods[PROT_SHA256_PK_REQUEST_PACKET]; in MYSQLND_METHOD()
2524 packet->header.persistent = persistent; in MYSQLND_METHOD()
2538 packet->header.m = &packet_methods[PROT_SHA256_PK_REQUEST_RESPONSE_PACKET]; in MYSQLND_METHOD()
2539 packet->header.persistent = persistent; in MYSQLND_METHOD()