summary refs log tree commit diff
path: root/demo
diff options
context:
space:
mode:
authorRichard van der Hoff <richard@matrix.org>2017-11-10 09:15:39 +0000
committerRichard van der Hoff <richard@matrix.org>2017-11-10 09:15:39 +0000
commitf90649eb2b0988c771fa329ba7a0a5ba81fe2396 (patch)
tree363a7733c8ac9fde637b754c75eca6874ea003d8 /demo
parentMerge pull request #2659 from matrix-org/rav/apparently_we_dont_follow_our_ow... (diff)
downloadsynapse-f90649eb2b0988c771fa329ba7a0a5ba81fe2396.tar.xz
Fix 500 on invalid utf-8 in request
If somebody sends us a request where the the body is invalid utf-8, we should
return a 400 rather than a 500. (json.loads throws a UnicodeError in this
situation)

We might as well catch all Exceptions here: it seems very unlikely that we
would get a request that *isn't caused by invalid json.
Diffstat (limited to 'demo')
0 files changed, 0 insertions, 0 deletions