| Index: net/quic/quic_data_writer.h
|
| diff --git a/net/quic/quic_data_writer.h b/net/quic/quic_data_writer.h
|
| index 8204c3af2c24bf4ed0c4fe40b3eac07e15f65b2f..4b5958efe57d18dd03d4053b361d2fade2602a5d 100644
|
| --- a/net/quic/quic_data_writer.h
|
| +++ b/net/quic/quic_data_writer.h
|
| @@ -20,20 +20,20 @@ namespace net {
|
| // This class provides facilities for packing QUIC data.
|
| //
|
| // The QuicDataWriter supports appending primitive values (int, string, etc)
|
| -// to a frame instance. The QuicDataWriter grows its internal memory buffer
|
| -// dynamically to hold the sequence of primitive values. The internal memory
|
| -// buffer is exposed as the "data" of the QuicDataWriter.
|
| +// to a frame instance. The internal memory buffer is exposed as the "data"
|
| +// of the QuicDataWriter.
|
| class NET_EXPORT_PRIVATE QuicDataWriter {
|
| public:
|
| - explicit QuicDataWriter(size_t length);
|
| + // Creates a QuicDataWriter where |buffer| is not owned.
|
| + QuicDataWriter(size_t size, char* buffer);
|
|
|
| ~QuicDataWriter();
|
|
|
| // Returns the size of the QuicDataWriter's data.
|
| size_t length() const { return length_; }
|
|
|
| - // Takes the buffer from the QuicDataWriter.
|
| - char* take();
|
| + // Retrieves the buffer from the QuicDataWriter without changing ownership.
|
| + char* data();
|
|
|
| // Methods for adding to the payload. These values are appended to the end
|
| // of the QuicDataWriter payload. Note - binary integers are written in
|
|
|