On 27/07/2010 7:00 PM, John J. Boyer wrote:
You're not supposed to have to worry about buffer sizes in Python. It should just give you the whole thing.I don't know much about Python, but couldn't the calling program provide the buffers and buffer sizes?
They aren't independent, though, because you need to know how long to make the output buffer so as to fit the entire translated input buffer. Unless you allocate a ridiculously huge output buffer all the time (and check that your input buffer never exceeds this), you have to try to guess how big to make outlen based on inlen.inlen and outlen are supposed to be independent.
How does liblouisxml determine the size of outlen? Jamie -- James Teh Vice President NV Access Inc, ABN 61773362390 Email: jamie@xxxxxxxxxxxx Web site: http://www.nvaccess.org/ For a description of the software and to download it go to http://www.jjb-software.com