fix(measurex): make sure we don't redirect loop forever (#532)
This is the most immediate fix to the issue described by https://github.com/ooni/probe/issues/1792. So, the logic was actually miss the increment, which would have been noticed with proper unit testing. Anyway, I am not sure why the loop ensues in the first time. By looking at the headers, it seems we're passing the headers correctly. So, even though this fix interrupts the loop, it still remains the question of whether the loop is legit or whether we're missing extra logic to properly redirect.
This commit is contained in:
parent
ba9151d4fa
commit
86018ecb82
|
@ -885,6 +885,7 @@ type redirectionQueue struct {
|
|||
|
||||
func (r *redirectionQueue) append(URL ...string) {
|
||||
r.q = append(r.q, URL...)
|
||||
r.cnt++
|
||||
}
|
||||
|
||||
func (r *redirectionQueue) popleft() (URL string) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user