<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p style="margin-top:0;margin-bottom:0">Hi Nikolay,<br>
</p>
18 6:36 AM, Alistair Leslie-Hughes wrote:<br>
<div style="color: rgb(0, 0, 0);">
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">> +    int size = 16656;<br>
<br>
<font size="2"><span style="font-size:11pt;">>  </span></font>Why this size? Is it reproducible with smaller buffer?<br>
This just happens to the size of the image I was embedding into a html file.<br>
I had two other images that failure as well and from memory they where bigger. <br>
As a test, I subtracted 2 from all the value returned in CryptBinaryToStringW<br>
<font size="2"><span style="font-size:11pt;">an</span></font>d nothing failed.  So, I'm guessing a smaller size would cause the issue as well.<br>
<br>
>I think this should test actual output, matching length alone is not enough.<br>
Sure, however I don't have a problem with the data itself just the size returned.<br>
<br>
Best Regards<br>
 Alistair.<br>
<br>
<br>
</div>
</span></font></div>
</div>
</div>
</body>
</html>