lesliejaneth / opencollada

Automatically exported from code.google.com/p/opencollada
0 stars 0 forks source link

Assertion failure on createAndWriteSkinControllers #110

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
on line 458, createUniqueIdFromUrl calls an unexpected overload, invoking 
createUniqueIdFromUrl(URL,id), passing false to absolute.
This causes an assertion failure

the fix is to change the call to look like
const COLLADAFW::UniqueId& sourceUniqueId = createUniqueIdFromUrl(*sourceUrl, 
COLLADAFW::SkinController::ID(), true);

Also: having those two overloads, one with integer and one with boolean is 
certainly confusing.  Making the overload require some other indication about 
which is being called would be preferable since there are likely to be other 
such bugs lurking in the codebase

Original issue reported on code.google.com by danie...@gmail.com on 23 Aug 2010 at 5:16

Attachments:

GoogleCodeExporter commented 8 years ago
Thanks for reporting this issue. However I have discovered and fixed that 
yesterday, too. Actually, the call should getUniqueIdByUrl instead of 
createUniqueIdFromUrl 

I have also changed the type of the ClassId from int to an enum. That should 
solve the confusion and lead to compiler errors in case of wrong usage.

Both changes can be found in rev 767 and 768.

Original comment by opencollada2@googlemail.com on 24 Aug 2010 at 11:13