mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Yannick Lecaillez
08.42.2016 ede52c8f25aa2b7815e006cdfd6fe09f0766b548
opendj-grizzly/src/main/java/org/forgerock/opendj/grizzly/ASN1BufferReader.java
@@ -145,24 +145,24 @@
     *            The maximum BER element size, or <code>0</code> to indicate
     *            that there is no limit.
     * @param buffer
     *            The buffer where the content will be read from.
     *            The buffer where the content will be read from. Note that
     *            @{code {@link #close()} this reader will also dispose the buffer.
     */
    ASN1BufferReader(final int maxElementSize, final Buffer buffer) {
        this.readLimiter = new RootSequenceLimiter();
        this.buffer = buffer;
        this.buffer.allowBufferDispose(false);
        this.maxElementSize = maxElementSize;
    }
    /**
     * Closes this ASN.1 reader and the underlying stream.
     * Closes this ASN.1 reader and the underlying {@link Buffer}.
     *
     * @throws IOException
     *             if an I/O error occurs
     */
    @Override
    public void close() throws IOException {
        // Nothing to do
        buffer.tryDispose();
    }
    /**