Django

Code

Show
Ignore:
Timestamp:
01/02/08 10:57:53 (1 year ago)
Author:
jbronn
Message:

gis: Merged revisions 6920-6989 via svnmerge from trunk.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/branches/gis

    • Property svnmerge-integrated changed from /django/trunk:1-6919 to /django/trunk:1-6989
  • django/branches/gis/django/views/static.py

    r6815 r6990  
    6060                              statobj[stat.ST_MTIME], statobj[stat.ST_SIZE]): 
    6161        return HttpResponseNotModified() 
    62     mimetype = mimetypes.guess_type(fullpath)[0] 
     62    mimetype = mimetypes.guess_type(fullpath)[0] or 'application/octet-stream' 
    6363    contents = open(fullpath, 'rb').read() 
    6464    response = HttpResponse(contents, mimetype=mimetype) 
    6565    response["Last-Modified"] = http_date(statobj[stat.ST_MTIME]) 
     66    response["Content-Length"] = len(contents) 
    6667    return response 
    6768