8c2 Subj : Proxy Service Issues To : Digital Man From : Drakmir Date : Fri Oct 14 2005 12:35:00 Re: Proxy Service Issues By: Digital Man to Drakmir on Tue Oct 11 2005 06:18 pm > Re: Proxy Service Issues > By: Drakmir to All on Fri Oct 07 2005 09:56 am > > > Re: Proxy Service Issues > > By: Drakmir to All on Thu Oct 06 2005 08:44 am > > > > So, after working on it last night and with some hints from Digital Man, > > come up with something that seems to work to proxy a socket. There is onl > > unknown, and I've noticed that the use of "sendBin" seems to be what is > > crashing my computer. (If I use any number of bytes other that 4 it seem > > occasionaly crash). > > What value (for number of byte) did you use when it crashed? Do you have > example code that can reproduce this crash? > > > The one sticky point is that when using "peek" or "read", sometimes you g > > string that is shorter than the number of bytes available to you. The on > > thing I can think of is that there is a embedded \0 character in the data > > stream which C is then reading as the end of the string. It would help t > > a read/write that dealt with the "string" we provide as a buffer instead. > > assume this is true because doing: > > > > socket.send("test\0test2"); only outputs "test". > > Ah, true. That'll be fixed for the next release. :-) > > digital man > > Snapple "Real Fact" #8: > A bee has 5 eyes. > Thanks! That should do it for me. I've changed the proxy code and TWGSRobotCode to send the byte, and over the past 3 days I've had no lockups. So, even though it was crashing using "sendBin(0, 1)" (since commenting out that code made the crash go away), I don't think it was that in particular. Maybe something that I was doing around it made that function fail dramatically? Anyway, the new proxy code sends the zero bytes now. I don't have an example to send you digital man, but if I get around to trying to recreate the crashes, I'll send it in. :) Thanks again for your help! Alan --- þ Synchronet þ Holodeck One - bbs.holodeckone.com . 0