CreateDeltaB function
Creates a delta between the source and target (provided as buffers) and returns the output delta as an MSDelta-allocated buffer.
Note
You must call DeltaFree to free the output buffer after this function has completed.
Syntax
BOOL WINAPI CreateDeltaB(
DELTA_FILE_TYPE FileTypeSet,
DELTA_FLAG_TYPE SetFlags,
DELTA_FLAG_TYPE ResetFlags,
DELTA_INPUT Source,
DELTA_INPUT Target,
DELTA_INPUT SourceOptions,
DELTA_INPUT TargetOptions,
DELTA_INPUT GlobalOptions,
const FILETIME *lpTargetFileTime,
ALG_ID HashAlgId,
LPDELTA_OUTPUT lpDelta
);
Parameters
FileTypeSet
[in] The DELTA_FILE_TYPE value that indicates the file type set to be used for the create process.
SetFlags
[in] One or more DELTA_FLAG_TYPE values that specify the flags to be used during the create process, in addition to the default flags.
ResetFlags
[in] One or more DELTA_FLAG_TYPE values that specify the default flags to be reset during the create process.
Source
[in] A DELTA_INPUT structure containing a pointer to the buffer containing the source data.
Target
[in] A DELTA_INPUT structure containing a pointer to the buffer containing the target data.
SourceOptions
[in] Reserved. Pass a DELTA_INPUT structure with Editable set to FALSE, lpStart set to NULL and uSize set to 0.
TargetOptions
[in] Reserved. Pass a DELTA_INPUT structure with Editable set to FALSE, lpStart set to NULL and uSize set to 0.
GlobalOptions
[in] Reserved. Pass a DELTA_INPUT structure with lpStart set to NULL and uSize set to 0.
lpTargetFileTime
[in] The time stamp set on the target file after delta apply. If NULL, the target timestamp will be the current time during the create process.
HashAlgId
[in] ALG_ID of the algorithm to be used to generate the target signature. Some special values are:
- 0 = No signature
- 32 = 32-bit CRC defined in msdelta.dll
lpDelta
[out] Pointer to the DELTA_OUTPUT structure where the delta is to be written.
Return value
This function returns TRUE if it succeeds; otherwise, it returns FALSE. When the function returns FALSE, you can call GetLastError to get the corresponding Win32 system error code.
Requirements
Requirement | Value |
---|---|
Header | msdelta.h |
DLL | msdelta.dll |
Unicode | Not applicable |