mirror of
				https://github.com/OpenFusionProject/OpenFusion.git
				synced 2025-10-31 08:40:12 +00:00 
			
		
		
		
	temp fix for U16toU8 edgecase
This commit is contained in:
		| @@ -1,8 +1,12 @@ | |||||||
| #include "CNStructs.hpp" | #include "CNStructs.hpp" | ||||||
|  |  | ||||||
| std::string U16toU8(char16_t* src) { | std::string U16toU8(char16_t* src) { | ||||||
|     std::wstring_convert<std::codecvt_utf8_utf16<char16_t>,char16_t> convert;  |     try { | ||||||
|     return convert.to_bytes(src);    |         std::wstring_convert<std::codecvt_utf8_utf16<char16_t>,char16_t> convert;  | ||||||
|  |         return convert.to_bytes(src);    | ||||||
|  |     } catch(std::exception e) { | ||||||
|  |         return ""; | ||||||
|  |     } | ||||||
| } | } | ||||||
|  |  | ||||||
| // returns number of char16_t that was written at des | // returns number of char16_t that was written at des | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user