mirror of
https://github.com/goatcorp/Dalamud.git
synced 2026-01-02 05:43:40 +01:00
Convert ReliableFileStorage to async
This commit is contained in:
parent
e65f441105
commit
20041be27c
6 changed files with 94 additions and 85 deletions
|
|
@ -52,7 +52,7 @@ internal class VfsWidget : IDataWindowWidget
|
|||
for (var i = 0; i < this.reps; i++)
|
||||
{
|
||||
stopwatch.Restart();
|
||||
service.WriteAllBytes(path, data);
|
||||
service.WriteAllBytesAsync(path, data).GetAwaiter().GetResult();
|
||||
stopwatch.Stop();
|
||||
acc += stopwatch.ElapsedMilliseconds;
|
||||
Log.Information("Turn {Turn} took {Ms}ms", i, stopwatch.ElapsedMilliseconds);
|
||||
|
|
@ -70,7 +70,7 @@ internal class VfsWidget : IDataWindowWidget
|
|||
for (var i = 0; i < this.reps; i++)
|
||||
{
|
||||
stopwatch.Restart();
|
||||
service.ReadAllBytes(path);
|
||||
service.ReadAllBytesAsync(path).GetAwaiter().GetResult();
|
||||
stopwatch.Stop();
|
||||
acc += stopwatch.ElapsedMilliseconds;
|
||||
Log.Information("Turn {Turn} took {Ms}ms", i, stopwatch.ElapsedMilliseconds);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue