X-Git-Url: https://git.mxchange.org/?p=quix0rs-apt-p2p.git;a=blobdiff_plain;f=apt_p2p%2FHTTPServer.py;h=b5a858d455b94f6e49749dcfc87cfac291c05497;hp=224f411db250a9bf2b2c989a8f3841fa1a9a21e1;hb=8b05746da5d94624a9d0f0840381010c6f209f66;hpb=eaecf245ed359e161b761e9c2d9ace4598ca5a20 diff --git a/apt_p2p/HTTPServer.py b/apt_p2p/HTTPServer.py index 224f411..b5a858d 100644 --- a/apt_p2p/HTTPServer.py +++ b/apt_p2p/HTTPServer.py @@ -214,7 +214,8 @@ class TopLevel(resource.Resource): return None, () # Find the file in the database - hash = unquote_plus(segments[1]) + # Have to unquote_plus the uri, because the segments are unquoted by twisted + hash = unquote_plus(request.uri[3:]) files = self.db.lookupHash(hash) if files: # If it is a file, return it