Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2013-09

Resolved: Carbon Application: Unable to open file "-psn_0_....."

2 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Schindler Karl-Michael

Hi

Date: Tue, 10 Sep 2013 01:24:25 +0200
From: Mattias Gaertner

Show quoted text 15 lines
On Mon, 9 Sep 2013 21:45:56 +0200 Schindler Karl-Michael wrote: > Hi > > I tried the program ddrescueview (http://sourceforge.net/projects/ddrescueview) on Mac OS X 10.6.8. The build goes well with Lazarus 1.0.12, but when running the program i get the error message: > > Unable to open file "-psn_0_....." > > If I click OK, the application proceeds and everything seems normal. Any idea, where this comes from and how to fix it? Have you tried to start it in the debugger and when the dialog appears to stop it and create a backtrace? Mattias

I finally found it. The problem was that the program accepts a file for opening from the first command line parameter. That's where the -psn_0_.... came from.

Thanks - Mischi.

Reply by email

Michalis Kamburelis
to Schindler Karl-Michael
Schindler Karl-Michael wrote
I finally found it. The problem was that the program accepts a file for opening from the first command line parameter. That's where the -psn_0_.... came from.

And the -psvn... option is under the hood passed to your programs when you run them from Finder on Mac OS X, see
http://forums.macrumors.com/showthread.php?t=207344 and http://stackoverflow.com/questions/10242115/os-x-strange-psn-command-line-parameter-when-launched-from-finder . When programming Mac OS X GUI programs that interpret command-line, you have to be ready to detect (and usually ignore) the -psvn... options.

Michalis

Reply by email