Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix issue Azure#24289
Browse files Browse the repository at this point in the history
blueww committed Mar 1, 2024

Verified

This commit was signed with the committer’s verified signature.
lgtm-migrator LGTM Migrator
1 parent 406941a commit 4232afb
Showing 2 changed files with 7 additions and 6 deletions.
3 changes: 3 additions & 0 deletions src/Storage/Storage.Management/ChangeLog.md
Original file line number Diff line number Diff line change
@@ -18,6 +18,9 @@
- Additional information about change #1
-->
## Upcoming Release
* Fixed upload file with OAuth authentication issue [#24289]
- `Set-AzStorageFileContent`

* Fixed parser logic when downloading blob from managed disk account with Sas Uri and bearer token on Linux and MacOS
- `Get-AzStorageBlobContent`
* Added warning messages for upcoming breaking changes in Queue cmdlets for removing references to "Microsoft.Azure.Storage.Queue"
10 changes: 4 additions & 6 deletions src/Storage/Storage/File/Cmdlet/SetAzureStorageFileContent.cs
Original file line number Diff line number Diff line change
@@ -244,12 +244,10 @@ await DataMovementTransferHelper.DoTransfer(() =>
{
long currentBlockSize = offset + blockSize < fileSize ? blockSize : fileSize - offset;

// Only need to create new buffer when chunk size change
if (currentBlockSize != lastBlockSize)
{
buffer = new byte[currentBlockSize];
lastBlockSize = currentBlockSize;
}
// create new buffer, the old buffer will be GC
buffer = new byte[currentBlockSize];
lastBlockSize = currentBlockSize;

await stream.ReadAsync(buffer: buffer, offset: 0, count: (int)currentBlockSize);
if (!fipsEnabled && hash != null)
{

0 comments on commit 4232afb

Please sign in to comment.