Ignore:
Timestamp:
Nov 15, 2013, 6:32:03 PM (6 years ago)
Author:
ldelgass
Message:

Remove some more Rappture deps from nanovis

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/vizservers/nanovis/ReadBuffer.cpp

    r3605 r4063  
    143143}
    144144
    145 ReadBuffer::BufferStatus
    146 ReadBuffer::followingData(Rappture::Buffer& out, size_t numBytes)
    147 {
    148     TRACE("Enter");
    149     while (numBytes > 0) {
    150         size_t bytesLeft;
    151 
    152         bytesLeft = _fill - _mark;
    153         if (bytesLeft > 0) {
    154             int size;
    155 
    156             /* Pull bytes out of the buffer, updating the mark. */
    157             size = (bytesLeft >  numBytes) ? numBytes : bytesLeft;
    158             out.append((const char *)_bytes + _mark, size);
    159             _mark += size;
    160             numBytes -= size;
    161         }
    162         if (numBytes == 0) {
    163             /* Received requested # bytes. */
    164             return ReadBuffer::OK;
    165         }
    166         /* Didn't get enough bytes, need to read some more. */
    167         _lastStatus = doFill();
    168         if (_lastStatus == ReadBuffer::ERROR ||
    169             _lastStatus == ReadBuffer::ENDFILE) {
    170             return _lastStatus;
    171         }
    172     }
    173     return ReadBuffer::OK;
    174 }
    175 
    176145/**
    177146 * \brief Returns the next available line (terminated by a newline)
Note: See TracChangeset for help on using the changeset viewer.