Fix DoS by infinite redirect loop:
- This fixes issue https://bugs.freenetproject.org/view.php?id=6042
Merge branch 'master' into event-notifications