Quoting Lloyd Bryant <[EMAIL PROTECTED]> from ml.softs.gtk-gnutella.devel:
:The attached patch (to "src/core/matching.c") implements this by generating 
:a random offset for the list of potential matches.  This offset is added to 
:the index (and wrapped around if it hits the end).  This way, a query will 
:receive different blocks of responses each time the same query is received.

This is very neat, and it has been in my TODO for a long time...

One comment on your patch though: it lacks comments.  I understand the
fix is simple, but when you read the code, nowhere does it say what it
does.

I'd summarize what you said in your message as comments in the code, so that
someone who takes a fresh view of the code can actually read the comments
and mentally reverse-engineer the code only if necessary (bug fixing or
refactoring).

Raphael

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Gtk-gnutella-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gtk-gnutella-devel

Reply via email to