These are chat archives for IndySockets/Indy

25th
Jul 2016
phy0292
@phy0292
Jul 25 2016 04:17
谁能看懂中文?
phy0292
@phy0292
Jul 25 2016 04:34
我有一个重要的BUG要报告,在indy10和之前的版本一直存在。在IdZLib.pas中的CompressStream里,如果我们以大于1比如9的压缩level来调用IdCompressorZLibEx1->DeflateStream(in_ms,out_ms,9);那么CompressStream函数发生buffer error的概率30%,你可以试试以这样的方式依次来压缩某个文件中每个文件,压缩结果可以舍弃不要,你会发现在压缩某些文件或内容时报buffer error的错误。而以默认的IdCompressorZLibEx1->DeflateStream(in_ms,out_ms);来调用这个函数不会出错,但是实际上他是不压缩数据,结果基本上都是变大。如果把 if strm.avail_in = 0 then break; 这一行改成if (strm.avail_in = 0) and (strm.avail_out > 0) then break; 那么BUG消除。。。
Matthijs ter Woord
@mterwoord
Jul 25 2016 06:20
@phy0292 You may have better luck trying in english...
davidpn
@davidpn
Jul 25 2016 07:55
He says there's a bug in IdZLib.pas
Matthijs ter Woord
@mterwoord
Jul 25 2016 07:59
what kind of bug?
davidpn
@davidpn
Jul 25 2016 07:59
He didn't say exactly where, but going by the example it looks like it's in IndyCompressStream, going by what he says the fix is
hard to work out exactly what the bug is
Dodgy Google Translate translation:
I have an important BUG to report, and the previous version in indy10 persist. In IdZLib.pas in CompressStream, if we is greater than 1, such as compression level 9 to call IdCompressorZLibEx1-> DeflateStream (in_ms, out_ms, 9); then CompressStream function generating buffer error probability of 30%, so you can try to way turn to compress each file in a file compression results do not give up, you will find some files in the compressed contents Times buffer error or mistake. The default of IdCompressorZLibEx1-> DeflateStream (in_ms, out_ms); call this function without error, but in fact he is not compressed data, the results are basically large. If if strm.avail_in = 0 then break; into this line if (strm.avail_in = 0) and (strm.avail_out> 0) then break; then eliminate BUG
His first question was whether anyone understands Chinese ;-)
Matthijs ter Woord
@mterwoord
Jul 25 2016 08:01
:)
davidpn
@davidpn
Jul 25 2016 08:03
Oops.. my bad.. there is a line of code like that in DoCompressStreamEx
Matthijs ter Woord
@mterwoord
Jul 25 2016 08:03
@davidpn I'd say we wait for him to translate to english?
davidpn
@davidpn
Jul 25 2016 08:03
as well
@phy0292 你可以提供一个更好的例子吗?
I asked for a better example
Matthijs ter Woord
@mterwoord
Jul 25 2016 08:05
you know english?
shoot, chinese?
davidpn
@davidpn
Jul 25 2016 08:05
lol
no.. I'm relying on Google Translate
hopefully Chinese (simplified) works ;-)
Matthijs ter Woord
@mterwoord
Jul 25 2016 08:06
:)
davidpn
@davidpn
Jul 25 2016 08:07
I think I need to learn Portugeuse.. most of the hits on my website are from Brazil.. must be a popular Delphi place :-)
phy0292
@phy0292
Jul 25 2016 08:56
稍后我提供一个案例放在git上,你们测试后就知道有严重的BUG存在。
davidpn
@davidpn
Jul 25 2016 08:57
谢谢 :-)
@davidpn 你会中文? :grinning:
davidpn
@davidpn
Jul 25 2016 09:50
不,我使用谷歌翻译 :-)
phy0292
@phy0292
Jul 25 2016 09:51
测试程序是个BCB代码,我没有用delphi
davidpn
@davidpn
Jul 25 2016 09:55
是的我知道。rlebeau 可能看后来. 我使用Delphi
I hope that worked out alright :-)
@rlebeau his link is to an example of what he thinks is a bug
in BCB
phy0292
@phy0292
Jul 25 2016 09:57
Please select "comp.dat" or "ExtWizrd.dll" file for testing
Ludwig Behm
@lbehm
Jul 25 2016 10:08
"hey just run these 2 binaries!" that looks kinda like phishing ^_^ must be the paranoia again x)
davidpn
@davidpn
Jul 25 2016 10:13
;-)
phy0292
@phy0292
Jul 25 2016 14:28
@davidpn 看到BUG了吗?
davidpn
@davidpn
Jul 25 2016 22:46
rlebeau以后可能检查的bug