Skip to content

Commit 0e42dc5

Browse files
committed
The Clear call isn't needed, is it?
1 parent e9cdbaf commit 0e42dc5

File tree

1 file changed

+0
-3
lines changed
  • Provider/src/FirebirdSql.Data.FirebirdClient/Client/Managed

1 file changed

+0
-3
lines changed

Provider/src/FirebirdSql.Data.FirebirdClient/Client/Managed/XdrStream.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -434,20 +434,17 @@ public short ReadInt16()
434434

435435
public int ReadInt32()
436436
{
437-
Array.Clear(_smallBuffer, 0, 4);
438437
ReadBytes(_smallBuffer, 4);
439438
return IPAddress.HostToNetworkOrder(BitConverter.ToInt32(_smallBuffer, 0));
440439
}
441440
public async Task<int> ReadInt32Async()
442441
{
443-
Array.Clear(_smallBuffer, 0, 4);
444442
await ReadBytesAsync(_smallBuffer, 4).ConfigureAwait(false);
445443
return IPAddress.HostToNetworkOrder(BitConverter.ToInt32(_smallBuffer, 0));
446444
}
447445

448446
public long ReadInt64()
449447
{
450-
Array.Clear(_smallBuffer, 0, 8);
451448
ReadBytes(_smallBuffer, 8);
452449
return IPAddress.HostToNetworkOrder(BitConverter.ToInt64(_smallBuffer, 0));
453450
}

0 commit comments

Comments
 (0)