IBackgroundCopyJobHttpOptions::GetCustomHeaders method

Retrieves the custom headers set by an earlier call to IBackgroundCopyJobHttpOptions::SetCustomHeaders (that is, headers which BITS will be sending to the remote, not headers which BITS receives from the remote).

Syntax


HRESULT GetCustomHeaders(
  [out] LPWSTR *pRequestHeaders
);

Parameters

pRequestHeaders [out]

Null-terminated string that contains the custom headers. Each header is terminated by a carriage return and line feed (CR/LF) character. To free the string when finished, call the CoTaskMemFree function.

Return value

The following table lists some of the possible return values.

Return codeDescription
S_OK

Successfully retrieved the headers.

S_FALSE

The job does not specify custom headers.

E_ACCESSDENIED

The user does not have permission to retrieve the custom headers.

RPC_X_NULL_REF_POINTER

The pRequestHeaders parameter is NULL.

 

Remarks

Only the job owner can retrieve the custom headers. To specify the headers, call the IBackgroundCopyJobHttpOptions::SetCustomHeaders method.

Requirements

Minimum supported client

Windows Vista

Minimum supported server

Windows Server 2008

Header

Bits2_5.h (include Bits.h)

IDL

Bits2_5.idl

Library

Bits.lib

See also

IBackgroundCopyJobHttpOptions
IBackgroundCopyJobHttpOptions::SetCustomHeaders

 

 

Show: