| 1554 | |
| 1555 | |
| 1556 | void Service::query(USHORT send_item_length, |
| 1557 | const UCHAR* send_items, |
| 1558 | USHORT recv_item_length, |
| 1559 | const UCHAR* recv_items, |
| 1560 | USHORT buffer_length, |
| 1561 | UCHAR* info) |
| 1562 | { |
| 1563 | ExistenceGuard guard(this, FB_FUNCTION); |
| 1564 | |
| 1565 | if (svc_flags & SVC_detached) |
| 1566 | { |
| 1567 | // Service was already detached |
| 1568 | Arg::Gds(isc_bad_svc_handle).raise(); |
| 1569 | } |
| 1570 | |
| 1571 | UCHAR item, *p; |
| 1572 | UCHAR buffer[256]; |
| 1573 | USHORT l, length, get_flags; |
| 1574 | |
| 1575 | try |
| 1576 | { |
| 1577 | // Process the send portion of the query first. |
| 1578 | USHORT timeout = 0; |
| 1579 | const UCHAR* items = send_items; |
| 1580 | const UCHAR* const end_items = items + send_item_length; |
| 1581 | while (items < end_items && *items != isc_info_end) |
| 1582 | { |
| 1583 | switch ((item = *items++)) |
| 1584 | { |
| 1585 | case isc_info_end: |
| 1586 | break; |
| 1587 | |
| 1588 | default: |
| 1589 | if (items + 2 <= end_items) |
| 1590 | { |
| 1591 | l = (USHORT) gds__vax_integer(items, 2); |
| 1592 | items += 2; |
| 1593 | if (items + l <= end_items) |
| 1594 | { |
| 1595 | switch (item) |
| 1596 | { |
| 1597 | case isc_info_svc_line: |
| 1598 | //put(items, l); |
| 1599 | break; |
| 1600 | case isc_info_svc_message: |
| 1601 | //put(items - 3, l + 3); |
| 1602 | break; |
| 1603 | case isc_info_svc_timeout: |
| 1604 | timeout = (USHORT) gds__vax_integer(items, l); |
| 1605 | break; |
| 1606 | case isc_info_svc_version: |
| 1607 | break; |
| 1608 | } |
| 1609 | } |
| 1610 | items += l; |
| 1611 | } |
| 1612 | else |
| 1613 | items += 2; |
nothing calls this directly
no test coverage detected