#2542 WcaInitialize does not validate input length ...

future
migrated
nobody
2013-08-21
2011-05-17
icnocop
No

WcaInitialize does not validate szCustomActionLogName is <= 32 characters and so if a longer string is passed it, the HRESULT is ambiguous.

For example, when I pass in a string with 33 characters in length, the returned HRESULT is 0x8007007A ERROR_INSUFFICIENT_BUFFER The data area passed to a system call is too small.

When in fact the data area passed in is too long.

I understand that this error is probably coming from ::StringCchCopy, but I think a more appropriate error message would be better.

Also, I did not notice any documentation for WcaInitialize() in any of the chm files, should there be one (ex. in the binaries zip)?

Thank you.

Discussion

  • icnocop

    icnocop - 2011-05-17

    This is some-what related to the following thread:
    http://www.mail-archive.com/wix-users@lists.sourceforge.net/msg39321.html
    [WiX-users] What can cause WcaInitialize to fail?

     
  • Rob Mensching

    Rob Mensching - 2013-08-21
    • Status: open --> migrated