Dear all,
why does the parseGeneralConfigStr function (used for parsing the MPEG4 
configuration header) return one more byte than I would expect?
Having a configuration string C the resulting byte array should have 
strlen(C)/2 bytes. Of course, if strlen(C) is odd (which should normally not be 
the case) it is safe to calculate the number of bytes as (strlen(C)+1)/2 which 
gives the same result for even numbers. But in the code the number of bytes is 
calculated as configSize = (strlen(configStr)+1)/2 + 1, which seems to leave 
one byte in the resulting byte array untouched filled with garbage. We 
discovered this issue after comparing the MPEG4 configuration bytes from 
live555 code with the data that we parsed out manually of a MPEG4 bitstream. 
MPEG4 decoders will not complain about this garbage byte, but I am correct that 
the last byte produced by the parseGeneralConfigStr function does not belong to 
the configuration header or am I completely wrong?
Thanks
Alex
_______________________________________________
live-devel mailing list
live-devel@lists.live555.com
http://lists.live555.com/mailman/listinfo/live-devel

Reply via email to