comparison src/org/eclipse/jetty/http/HttpGenerator.java @ 1022:3718afd99988

HttpHeaders uses StringCache
author Franklin Schmidt <fschmidt@gmail.com>
date Tue, 01 Nov 2016 01:04:46 -0600
parents e350c11242be
children 563458c4dc93
comparison
equal deleted inserted replaced
1021:e350c11242be 1022:3718afd99988
604 // we have seen all the _content there is 604 // we have seen all the _content there is
605 _contentLength = _contentWritten; 605 _contentLength = _contentWritten;
606 if (content_length == null && (isResponse() || _contentLength>0 || content_type ) && !_noContent) 606 if (content_length == null && (isResponse() || _contentLength>0 || content_type ) && !_noContent)
607 { 607 {
608 // known length but not actually set. 608 // known length but not actually set.
609 _header.put(HttpHeaders.CONTENT_LENGTH_BUFFER); 609 _header.put(HttpHeaders.CONTENT_LENGTH_BYTES);
610 _header.put(HttpTokens.COLON); 610 _header.put(HttpTokens.COLON);
611 _header.put((byte) ' '); 611 _header.put((byte) ' ');
612 BufferUtil.putDecLong(_header, _contentLength); 612 BufferUtil.putDecLong(_header, _contentLength);
613 _header.put(HttpTokens.CRLF); 613 _header.put(HttpTokens.CRLF);
614 } 614 }