Bug in CurrentDir() or possibly GetCurrentDirName() ?

A forum for general AmigaOS 4.x support questions that are not platform-specific
xenic
Posts: 1185
Joined: Sun Jun 19, 2011 12:06 am

Re: Bug in CurrentDir() or possibly GetCurrentDirName() ?

Post by xenic »

@thomasrapp
Your explanation should be added to the autodoc to avoid the kind of confusion experienced by ChrisH and myself. Even after rereading the GetCurrentDirName() autodoc and noting that it gets the name from the CLI structure, I still had the wrong impression about the name returned by the function.
AmigaOne X1000 with 2GB memory - OS4.1 FE
User avatar
ChrisH
Beta Tester
Beta Tester
Posts: 920
Joined: Mon Dec 20, 2010 9:09 pm
Contact:

Re: Bug in CurrentDir() or possibly GetCurrentDirName() ?

Post by ChrisH »

thomasrapp wrote:The CD command sets it and the prompt %s placeholder reads it. It's not used anywhere else.
Thanks for your explanation!

Get/SetCurrentDirName() seems kinda pointless though - you'd think that CurrentDir() should automatically call SetCurrentDirName(), and that GetCurrentDirName() could then just be a simple wrapper for "NameFromLock(myProcess.pr_CurrentDir)"... (Perhaps I am missing something?)
Post Reply