Compare commits

..
2 changed files with 7 additions and 11 deletions

View file

@ -57,15 +57,12 @@ class ClientController extends AsyncNotifier<int> {
for (final MapEntry(:key, :value) in env.entries) {
final keyPtr = key.toNativeUtf8().cast<Char>();
final valuePtr = value.toNativeUtf8().cast<Char>();
try {
GomuksSetEnv(keyPtr, valuePtr);
} finally {
calloc
..free(keyPtr)
..free(valuePtr);
}
}
}
debugPrint("Initializing Gomuks...");
final handle = await Isolate.run(() {
@ -110,9 +107,8 @@ class ClientController extends AsyncNotifier<int> {
return json;
} finally {
calloc
..free(bufferPointer.ref.base)
..free(bufferPointer);
calloc.free(bufferPointer.ref.base);
calloc.free(bufferPointer);
}
}

View file

@ -71,7 +71,7 @@ final class ChatScroll<T>({
if (position.extentAfter <= topThreshold) {
await loadOlder();
} else if (position.extentBefore <= bottomThreshold) {
await onReachedBottom();
onReachedBottom();
}
}