Zebediah Figura z.figura12@gmail.com writes:
I'm not sure what you are trying to fix. Most places already check that blocknr is >= 0, and if it's really negative, you can't rely on right shift doing the right thing.
On 02/20/2017 03:39 AM, Alexandre Julliard wrote:
Without the patch, I get failed assertions in several places that the blocknr is >= 0. With it, it seems to pass that -1 on to the program, causing it not to crash. This might be fixing the symptom rather than the cause, though.
On 02/20/2017 08:23 AM, Zebediah Figura wrote:
My apologies. To be more accurate, the game crashes because this function is passed blocknr=12, nr=1, so when the loop is executed, lastblocknr/128 == blocknr/128 == 0, so the assertion "lastblocknr >= 0" fails. If there is a better way to fix this, I do not know what it is.