Bug in CurrentDir() or possibly GetCurrentDirName() ?

A forum for general AmigaOS 4.x support questions that are not platform-specific

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

Postby xenic » Tue Sep 27, 2011 5:03 pm

@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
xenic
 
Posts: 1160
Joined: Sun Jun 19, 2011 1:06 am

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

Postby ChrisH » Tue Sep 27, 2011 5:54 pm

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?)
User avatar
ChrisH
Beta Tester
Beta Tester
 
Posts: 915
Joined: Mon Dec 20, 2010 10:09 pm

Previous

Return to General AmigaOS

Who is online

Users browsing this forum: No registered users and 3 guests