diff options
author | Dimitri van Heesch <dimitri@stack.nl> | 2009-12-22 16:03:24 (GMT) |
---|---|---|
committer | Dimitri van Heesch <dimitri@stack.nl> | 2009-12-22 16:03:24 (GMT) |
commit | e32567534d95ff3960fa4dcad7733c18e1b39bc5 (patch) | |
tree | ed7891ebf8c1dbed877ba72eecb07d5da29b4978 /src/bufstr.h | |
parent | 6f2abee157d4310a8272ca0f748ce6b812ae7260 (diff) | |
download | Doxygen-e32567534d95ff3960fa4dcad7733c18e1b39bc5.zip Doxygen-e32567534d95ff3960fa4dcad7733c18e1b39bc5.tar.gz Doxygen-e32567534d95ff3960fa4dcad7733c18e1b39bc5.tar.bz2 |
Release-1.6.1-20091222
Diffstat (limited to 'src/bufstr.h')
-rw-r--r-- | src/bufstr.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/bufstr.h b/src/bufstr.h index 4ce1dae..083d5b0 100644 --- a/src/bufstr.h +++ b/src/bufstr.h @@ -93,6 +93,13 @@ class BufStr { return m_writeOffset; } + void dropFromStart(uint bytes) + { + if (bytes>m_size) bytes=m_size; + if (bytes>0) qmemmove(m_buf,m_buf+bytes,m_size-bytes); + m_size-=bytes; + m_writeOffset-=bytes; + } private: void makeRoomFor(uint size) { |