[hatari-devel] Wotanoid problem : final fix before commit ?

Laurent Sallafranque laurent.sallafranque at free.fr
Sun Jan 24 19:16:42 CET 2010


> My  memory  is  a bit hazy, but I think this just tells gemdos to
> read $ffffffff  bytes  from the file. Of course gemdos will read as
> much as the  file  size  and then return an error in d0.l. It's the


Which error should be set to D0 in this case ?
I can add it with the patch.

> Laurent, why you apply the patch, add to code a comment about what George
> mentioned above.

Eero, what do you want me to add as a comment exactly ?


> I guess Fwrite() size should then be Uint32 too, what do you think?

I thought about this too this afternoon.
There are probably some other places where we may have this bug.
But I'm not an expert of Gemdos like you and your help is needed here.

I'll upload the patch tonigh, after you tell me what to add as comments
and which value to add to D0.

Regards

Laurent



Eero Tamminen a écrit :
> Hi,
>
> On Sunday 24 January 2010, George Nakos wrote:
>   
>> Sunday, January 24, 2010, 1:42:02 PM, you wrote:
>>     
>>> On Sunday 24 January 2010, Laurent Sallafranque wrote:
>>>       
>>>>>>> I've looked at the compendium.
>>>>>>> I haven't found anything about this -1 length call.
>>>>>>>               
>>>>>> My  memory  is  a bit hazy, but I think this just tells gemdos to
>>>>>> read $ffffffff  bytes  from the file. Of course gemdos will read as
>>>>>> much as the  file  size  and then return an error in d0.l. It's the
>>>>>> lazy man's approach  to  doing  things  the  Right Way(tm) (i.e.
>>>>>> getting the file length  -or knowing it beforehand- and calling
>>>>>> fread() with the proper amount of bytes)
>>>>>>             
>>> George, have you actually used this on actual HW so that it has worked?
>>> With which TOS version(s) it works like that?
>>>       
>> Yup,  on  a STE with TOS 1.62UK and STFM with TOS 1.02UK. Also, that's
>> we use that in ULSv3 for a couple of years now and it works in all our
>> test equipment (MSTEs, Falcons, a TT, etc)
>>     
>
> Thanks.  Then it seems that EmuTOS is (as usual) broken and documentation
> is wrong too & Laurent's patch is fine.
>
> Laurent, why you apply the patch, add to code a comment about what George
> mentioned above.
>
> I guess Fwrite() size should then be Uint32 too, what do you think?
>
> (It goes to fwrite which uses size_t, so it's converted to unsigned
> anyway...)
>
>
> 	- Eero
> _______________________________________________
> hatari-devel mailing list
> hatari-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/hatari-devel
>
>
>   




More information about the hatari-devel mailing list