summaryrefslogtreecommitdiff
path: root/paste/urlparser.py
diff options
context:
space:
mode:
authorianb <devnull@localhost>2005-10-04 23:16:32 +0000
committerianb <devnull@localhost>2005-10-04 23:16:32 +0000
commite549d1a8ac5550d4e0345178e3deab41f502a619 (patch)
tree56c017fd424dcfd019ea29f9b1121e6f32972c39 /paste/urlparser.py
parent8ae5eedc501d18c0f5fb47611ff5fd0ff2e34b24 (diff)
downloadpaste-e549d1a8ac5550d4e0345178e3deab41f502a619.tar.gz
Default type when mimetypes returns None
Diffstat (limited to 'paste/urlparser.py')
-rw-r--r--paste/urlparser.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/paste/urlparser.py b/paste/urlparser.py
index 8ad2eb7..c049a1c 100644
--- a/paste/urlparser.py
+++ b/paste/urlparser.py
@@ -508,6 +508,8 @@ class PkgResourcesParser(StaticURLParser):
return self.error_extra_path(environ, start_response)
type, encoding = mimetypes.guess_type(resource)
+ if not type:
+ type = 'application/octet-stream'
# @@: I don't know what to do with the encoding.
try:
file = self.egg.get_resource_stream(self.manager, resource)