What does HRESULT 0x80072EEA (WININET_E_BAD_OPTION_LENGTH) mean?

 
Previous Next
WININET_E_INVALID_OPTION WININET_E_OPTION_NOT_SETTABLE

WININET_E_BAD_OPTION_LENGTH

WININET_E_BAD_OPTION_LENGTH is a WinINet HRESULT. It means that the value size supplied for a WinINet option does not match the type expected by that option. It can result from using a character count instead of a byte count, passing the wrong structure, or using an incompatible string encoding.

What to check

  • Pass the option value length in bytes and use the data type or structure required by the specific option.
  • Check ANSI versus Unicode calls, structure packing and the lifetime of buffers passed to asynchronous operations.
  • Initialize option structures completely and avoid reusing a size value intended for a different option.

Microsoft: WinINet overview


Looking for a different code? Search another status or error code.