Mercurial Hosting > luan
comparison src/org/eclipse/jetty/server/handler/ResourceHandler.java @ 1023:27f3dc761452
MimeTypes uses StringCache
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Tue, 01 Nov 2016 03:44:46 -0600 |
parents | 3718afd99988 |
children | 921c25a05eaa |
comparison
equal
deleted
inserted
replaced
1022:3718afd99988 | 1023:27f3dc761452 |
---|---|
383 response.setStatus(HttpStatus.NOT_MODIFIED_304); | 383 response.setStatus(HttpStatus.NOT_MODIFIED_304); |
384 return; | 384 return; |
385 } | 385 } |
386 } | 386 } |
387 | 387 |
388 Buffer mime=_mimeTypes.getMimeByExtension(resource.toString()); | 388 String mime = _mimeTypes.getMimeByExtension(resource.toString()); |
389 if (mime==null) | 389 if (mime==null) |
390 mime=_mimeTypes.getMimeByExtension(request.getPathInfo()); | 390 mime=_mimeTypes.getMimeByExtension(request.getPathInfo()); |
391 | 391 |
392 // set the headers | 392 // set the headers |
393 doResponseHeaders(response,resource,mime!=null?mime.toString():null); | 393 doResponseHeaders(response,resource,mime); |
394 response.setDateHeader(HttpHeaders.LAST_MODIFIED,last_modified); | 394 response.setDateHeader(HttpHeaders.LAST_MODIFIED,last_modified); |
395 | 395 |
396 if(skipContentBody) | 396 if(skipContentBody) |
397 return; | 397 return; |
398 // Send the content | 398 // Send the content |