Hi Iczelion, I am wondering about the Instring function in your HTTP Downloader sample. Should the buffers passed to it be evenly divisible by 4 (DWORD)? Why is this InString function different from the one distributed with MASM32? Is it better? I think the MASM32 function has a "register trashing" bug. Can't say for sure though... Thanks! Xtreme
Posted on 2001-03-10 05:53:00 by xtreme
xtreme, The InString procedure in MASM32 has been very rigourously tested and when there was a report of a problem, it was tested just as hard again and I could not reproduce the error reported. Where it is fussy is that it MUST have correctly zero terminated strings passed to it, both source and search string and if this is not done, it will generate a page write fault when it gets past the end of either buffer. It preserves all of the correct registers, it will handle high speed recursive calls and it balances the stack correctly. So far no-one can reproduce a problem so I think the original reported problem came from programming error, not algo problems. In its current form, it is not suitable for binary search, it was designed for TEXT search so the correct terminators MUST be used. If that's what you need to do in your prog, try it as it is also very fast for a search algo. It uses a method of first character match, branch compare and exit on search string match. Regards, hutch@pbq.com.au
Posted on 2001-03-10 08:42:00 by hutch--
Thanks hutch, It seems that the InString function wasn't the problem at all it was my method of placing data into the buffer that needed adjustment... Thanks, Xtreme
Posted on 2001-03-11 17:30:00 by xtreme