cake_wallet/cw_haven/lib/api/convert_utf8_to_string.dart

8 lines
175 B
Dart
Raw Normal View History

2022-02-21 19:11:18 +00:00
import 'dart:ffi';
import 'package:ffi/ffi.dart';
String convertUTF8ToString({Pointer<Utf8> pointer}) {
final str = Utf8.fromUtf8(pointer);
free(pointer);
return str;
}