| 746 | |
| 747 | |
| 748 | CsConvert INTL_convert_lookup(thread_db* tdbb, CHARSET_ID to_cs, CHARSET_ID from_cs) |
| 749 | { |
| 750 | /************************************** |
| 751 | * |
| 752 | * I N T L _ c o n v e r t _ l o o k u p |
| 753 | * |
| 754 | ************************************** |
| 755 | * |
| 756 | * Functional description |
| 757 | * |
| 758 | **************************************/ |
| 759 | |
| 760 | SET_TDBB(tdbb); |
| 761 | Database* dbb = tdbb->getDatabase(); |
| 762 | CHECK_DBB(dbb); |
| 763 | |
| 764 | if (from_cs == CS_dynamic) |
| 765 | from_cs = tdbb->getCharSet(); |
| 766 | |
| 767 | if (to_cs == CS_dynamic) |
| 768 | to_cs = tdbb->getCharSet(); |
| 769 | |
| 770 | // Should from_cs == to_cs? be handled better? YYY |
| 771 | |
| 772 | fb_assert(from_cs != CS_dynamic); |
| 773 | fb_assert(to_cs != CS_dynamic); |
| 774 | |
| 775 | CharSetContainer* charset = CharSetContainer::lookupCharset(tdbb, from_cs); |
| 776 | |
| 777 | return charset->lookupConverter(tdbb, to_cs); |
| 778 | } |
| 779 | |
| 780 | |
| 781 | void INTL_convert_string(dsc* to, const dsc* from, Firebird::Callbacks* cb) |
no test coverage detected