projects
/
goodguy
/
history.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
wheels for crikey, xml tweak and edl fix for nesting
[goodguy/history.git]
/
cinelerra-5.1
/
cinelerra
/
filexml.C
diff --git
a/cinelerra-5.1/cinelerra/filexml.C
b/cinelerra-5.1/cinelerra/filexml.C
index 1da5a5e067359d0a8aae04af44f59ced9bed0a64..aef297e41adf822d9c697cda88a7cdb05130dbe0 100644
(file)
--- a/
cinelerra-5.1/cinelerra/filexml.C
+++ b/
cinelerra-5.1/cinelerra/filexml.C
@@
-76,9
+76,10
@@
XMLBuffer::~XMLBuffer()
unsigned char *&XMLBuffer::demand(long len)
{
if( len > bsz ) {
unsigned char *&XMLBuffer::demand(long len)
{
if( len > bsz ) {
- len += BCTEXTLEN;
+ long sz = inp-bfr;
+ len += sz/2 + BCTEXTLEN;
unsigned char *np = new unsigned char[len];
unsigned char *np = new unsigned char[len];
- if(
inp > bfr ) memcpy(np,bfr,inp-bfr
);
+ if(
sz > 0 ) memcpy(np,bfr,sz
);
inp = np + (inp-bfr);
outp = np + (outp-bfr);
lmt = np + len; bsz = len;
inp = np + (inp-bfr);
outp = np + (outp-bfr);
lmt = np + len; bsz = len;