Re: NSString and file system Re: AppleScript in Sandboxed App

2013-02-03 Thread Daniel Höpfl
Hello, On Wed, 16 Jan 2013 17:12:15 +, jonat...@mugginsoft.com wrote: On 16 Jan 2013, at 15:50, Fritz Anderson wrote: On 16 Jan 2013, at 3:52 AM, "jonat...@mugginsoft.com" wrote: Py_SetProgramName((char *)[[scriptRunner launchPath] UTF8String]); If a char* is destined for t

Re: NSString and file system Re: AppleScript in Sandboxed App

2013-01-18 Thread Mike Abdullah
On 16 Jan 2013, at 17:40, Quincey Morris wrote: > On Jan 16, 2013, at 09:12 , "jonat...@mugginsoft.com" > wrote: > >> To be honest I rarely remember to call -fileSystemRepresentation. >> The docs seem to indicate that its only purpose is to replace abstract / and >> . characters with OS equ

Re: NSString and file system Re: AppleScript in Sandboxed App

2013-01-16 Thread Quincey Morris
On Jan 16, 2013, at 09:12 , "jonat...@mugginsoft.com" wrote: > To be honest I rarely remember to call -fileSystemRepresentation. > The docs seem to indicate that its only purpose is to replace abstract / and > . characters with OS equivalents. > On OS X this would have seem to have no net resul

Re: NSString and file system Re: AppleScript in Sandboxed App

2013-01-16 Thread jonat...@mugginsoft.com
On 16 Jan 2013, at 15:50, Fritz Anderson wrote: > On 16 Jan 2013, at 3:52 AM, "jonat...@mugginsoft.com" > wrote: > >> Py_SetProgramName((char *)[[scriptRunner launchPath] UTF8String]); > > If a char* is destined for the file system, you should be using > -fileSystemRepresentation, not

NSString and file system Re: AppleScript in Sandboxed App

2013-01-16 Thread Fritz Anderson
On 16 Jan 2013, at 3:52 AM, "jonat...@mugginsoft.com" wrote: > Py_SetProgramName((char *)[[scriptRunner launchPath] UTF8String]); If a char* is destined for the file system, you should be using -fileSystemRepresentation, not -UTF8String. I forget that all the time. — F -- Fri