mirror of
https://github.com/esiur/esiur-dart.git
synced 2025-06-27 14:53:11 +00:00
1.2.2
This commit is contained in:
@ -260,36 +260,24 @@ class DistributedConnection extends NetworkConnection with IStore
|
||||
|
||||
Future<bool> reconnect() async
|
||||
{
|
||||
try
|
||||
{
|
||||
if (await connect())
|
||||
{
|
||||
try
|
||||
{
|
||||
var bag = AsyncBag();
|
||||
var bag = AsyncBag();
|
||||
|
||||
for(var i = 0; i < _resources.keys.length; i++)
|
||||
{
|
||||
var index = _resources.keys.elementAt(i);
|
||||
// print("Re $i ${_resources[index].instance.template.className}");
|
||||
bag.add(fetch(index));
|
||||
}
|
||||
|
||||
bag.seal();
|
||||
await bag;
|
||||
}
|
||||
catch(ex)
|
||||
for(var i = 0; i < _resources.keys.length; i++)
|
||||
{
|
||||
print(ex.toString());
|
||||
var index = _resources.keys.elementAt(i);
|
||||
// print("Re $i ${_resources[index].instance.template.className}");
|
||||
bag.add(fetch(index));
|
||||
}
|
||||
|
||||
bag.seal();
|
||||
await bag;
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
catch(ex)
|
||||
{
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -220,6 +220,9 @@ class IIPPacket
|
||||
var cl = data.getUint32( offset);
|
||||
offset += 4;
|
||||
|
||||
if (_notEnough(offset, ends, cl))
|
||||
return -_dataLengthNeeded;
|
||||
|
||||
content = data.clip(offset, cl);
|
||||
offset += cl;
|
||||
|
||||
|
Reference in New Issue
Block a user