0

Hi Apple // enthusiasts,

I have a simple program on my Apple IIc in assembly language. It starts by getting a filename from the user (GETLN), then it opens the corresponding file with a MLI call ($C8) To my suprise, the MLI call returned error # $40 : "Pathname has invalid syntax" I have checked all parameters, but they where OK. I have tried to type PREFIX /myvolume before starting my program. And this time, it worked !! (the file was opened without any error). I undertood that when you start prodos (just prodos and basic.system), then te prefix is empty. I have ckecked it, by replacing the openfile MLI call by a get_prefix call. And yes, the prefix length is 0.

Did you know that ? Until then, I believed that the prefix was set to the root prefix of the booting disk by the system at boot.

For the story, I have found a worknaround reading the path of the runnning program (my program in that case) at memory address $280, and calling set_prefix to that path. A lot of assembly lines.

Can you confirm my analyse ?

Thanks

bruno185
  • 1
  • 1
  • 1
    FYI, questions like this often get better answers on https://retrocomputing.stackexchange.com/. Might want to delete this and repost there. – Peter Cordes Feb 08 '21 at 21:51
  • I’m voting to close this question because it is better suited for https://retrocomputing.stackexchange.com/ and is unlikely to receive answers here anyway. – costaparas Feb 09 '21 at 05:36
  • Thank you all for your advice, it was my first post here, now reposted on retrocomputing.stackexchange.com. – bruno185 Feb 10 '21 at 10:51

0 Answers0