mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-10 13:13:44 +01:00
note an assert trigger, if you use an old broken netscape socks4
svn:r1022
This commit is contained in:
parent
c1cbb16e6f
commit
b42b16357f
@ -532,6 +532,9 @@ int fetch_from_buf_socks(buf_t *buf, socks_request_t *req) {
|
|||||||
}
|
}
|
||||||
log_fn(LOG_DEBUG,"Everything is here. Success.");
|
log_fn(LOG_DEBUG,"Everything is here. Success.");
|
||||||
strcpy(req->address, socks4_prot == socks4 ? tmpbuf : startaddr);
|
strcpy(req->address, socks4_prot == socks4 ? tmpbuf : startaddr);
|
||||||
|
/* XXX on very old netscapes (socks4) the next line triggers an
|
||||||
|
* assert, because next-buf->mem+1 is greater than buf->datalen.
|
||||||
|
*/
|
||||||
buf_remove_from_front(buf, next-buf->mem+1); /* next points to the final \0 on inbuf */
|
buf_remove_from_front(buf, next-buf->mem+1); /* next points to the final \0 on inbuf */
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user