[Bug 5137] avifil32 limits itself to max of 1024 frames when writing avis

wine-bugs at winehq.org wine-bugs at winehq.org
Mon Jun 16 18:37:31 CDT 2008


http://bugs.winehq.org/show_bug.cgi?id=5137





--- Comment #7 from Luke Bratch <l_bratch at yahoo.co.uk>  2008-06-16 18:37:31 ---
Angus, please post in Bugzilla instead of replying to wine-bugs.  Email read:

"You can clearly see in AVIFILE_AddRecord():

1453   if (This->idxRecords == NULL || This->cbIdxRecords == 0) {

1454     This->cbIdxRecords += 1024 * sizeof(AVIINDEXENTRY);
1455     This->idxRecords = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY,
This->cbIdxRecords);

1456     if (This->idxRecords == NULL)

1457       return AVIERR_MEMORY;
1458   }

1459 
1460   assert(This->nIdxRecords < This->cbIdxRecords/sizeof(AVIINDEXENTRY));

This->cbIdxRecords == 0 the first time through and the array gets allocated to
1024*sizeof(AVIINDEXENTRY).  Then the assert on line 1460 makes sure we never
go over it.  The fix is a simple twist to the logic to realloc instead of
asserting when nIdxRecords gets too big.

Unless this function changes, there's no point pinging the bug to see if its
changed :P"


-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
Do not reply to this email, post in Bugzilla using the
above URL to reply.
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the wine-bugs mailing list