| 758 | |
| 759 | |
| 760 | static const UCHAR* sdl_desc(const UCHAR* ptr, DSC* desc) |
| 761 | { |
| 762 | /************************************** |
| 763 | * |
| 764 | * s d l _ d e s c |
| 765 | * |
| 766 | ************************************** |
| 767 | * |
| 768 | * Functional description |
| 769 | * Parse BLR descriptor into internal descriptor. |
| 770 | * Return updated pointer is successful, otherwise NULL. |
| 771 | * |
| 772 | **************************************/ |
| 773 | const UCHAR* sdl = ptr; |
| 774 | desc->dsc_scale = 0; |
| 775 | desc->dsc_length = 0; |
| 776 | desc->dsc_sub_type = 0; |
| 777 | desc->dsc_flags = 0; |
| 778 | |
| 779 | switch (*sdl++) |
| 780 | { |
| 781 | case blr_text2: |
| 782 | desc->dsc_dtype = dtype_text; |
| 783 | desc->setTextType(get_word(sdl)); |
| 784 | break; |
| 785 | |
| 786 | case blr_text: |
| 787 | desc->dsc_dtype = dtype_text; |
| 788 | desc->setTextType(ttype_dynamic); |
| 789 | desc->dsc_flags |= DSC_no_subtype; |
| 790 | break; |
| 791 | |
| 792 | case blr_cstring2: |
| 793 | desc->dsc_dtype = dtype_cstring; |
| 794 | desc->setTextType(get_word(sdl)); |
| 795 | break; |
| 796 | |
| 797 | case blr_cstring: |
| 798 | desc->dsc_dtype = dtype_cstring; |
| 799 | desc->setTextType(ttype_dynamic); |
| 800 | desc->dsc_flags |= DSC_no_subtype; |
| 801 | break; |
| 802 | |
| 803 | case blr_varying2: |
| 804 | desc->dsc_dtype = dtype_cstring; |
| 805 | desc->setTextType(get_word(sdl)); |
| 806 | desc->dsc_length = sizeof(USHORT); |
| 807 | break; |
| 808 | |
| 809 | case blr_varying: |
| 810 | desc->dsc_dtype = dtype_cstring; |
| 811 | desc->setTextType(ttype_dynamic); |
| 812 | desc->dsc_length = sizeof(USHORT); |
| 813 | desc->dsc_flags |= DSC_no_subtype; |
| 814 | break; |
| 815 | |
| 816 | case blr_short: |
| 817 | desc->dsc_dtype = dtype_short; |
no test coverage detected