Skip to content

Commit

Permalink
Add PrepareForSend to deal with "no data" operations
Browse files Browse the repository at this point in the history
  • Loading branch information
josesimoes committed Mar 20, 2024
1 parent 6c04fe7 commit e4ba0de
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -643,6 +643,13 @@ public override bool PrepareForSend(
return true;
}

internal void PrepareForSend()
{
// add the file name to the data property buffer
Data = Encoding.UTF8.GetBytes(FileName);
NameLength = (uint)FileName.Length;
}

//////////////////////////////////////////////////////////////////////////////////////
// !!! KEEP IN SYNC WITH typedef enum Monitor_StorageOperation (in native code) !!! //
//////////////////////////////////////////////////////////////////////////////////////
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4494,6 +4494,8 @@ public StorageOperationErrorCode DeleteStorageFile(string fileName)
Commands.Monitor_StorageOperation.StorageOperation.Delete,
fileName);

storop.PrepareForSend();

IncomingMessage reply = PerformSyncRequest(
Commands.c_Monitor_StorageOperation,
0,
Expand Down

0 comments on commit e4ba0de

Please sign in to comment.