Recent

Author Topic: psn_0_23787182 when running bundle  (Read 3290 times)

circular

  • Hero Member
  • *****
  • Posts: 4221
    • Personal webpage
psn_0_23787182 when running bundle
« on: February 09, 2012, 10:52:59 am »
I've asked someone to compile LazPaint on MacOS, but there was the following error when running the bundle (not when using the play button in Lazarus) :

Unknown command : psn_0_23787182

What can we do about it ?
Conscience is the debugger of the mind

Shebuka

  • Sr. Member
  • ****
  • Posts: 427
Re: psn_0_23787182 when running bundle
« Reply #1 on: February 09, 2012, 11:10:16 am »
ignore it, it's a random launch ParamStr, i got this -psn_0_1020153 now on my app, and this -psn_0_1032444 and so on.

felipemdc

  • Administrator
  • Hero Member
  • *
  • Posts: 3538
Re: psn_0_23787182 when running bundle
« Reply #2 on: February 09, 2012, 12:16:37 pm »
Mac OS X sends it, I don't know what for.

circular

  • Hero Member
  • *****
  • Posts: 4221
    • Personal webpage
Re: psn_0_23787182 when running bundle
« Reply #3 on: February 09, 2012, 06:19:07 pm »
Ok, got it. Thanks !
Conscience is the debugger of the mind

Phil

  • Hero Member
  • *****
  • Posts: 2737
Re: psn_0_23787182 when running bundle
« Reply #4 on: February 09, 2012, 06:42:21 pm »
If you're using ParamStr to detect files passed to the app, that won't work with OS X. Here's how to do that:

http://web.me.com/macpgmr/ObjP/MacXPlatform_Part8.html#DropFiles

Thanks.

-Phil

trev

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2023
  • Former Delphi 1-7, 10.2 user
Re: psn_0_23787182 when running bundle
« Reply #5 on: May 22, 2020, 02:35:38 pm »
[Yes - I know - ancient history, but I ran into the issue today and as I have more info...]

Quote
ProcessSerialNumber
Defines the unique identifier for an open process.

struct ProcessSerialNumber {
   unsigned long highLongOfPSN;
      unsigned long lowLongOfPSN;
      };
      typedef struct ProcessSerialNumber ProcessSerialNumber;
      typedef ProcessSerialNumber * ProcessSerialNumberPtr;
      Field Descriptions
      highLongOfPSN
      The high-order long integer of the process serial number.

      lowLongOfPSN
      The low-order long integer of the process serial number.

      Discussion
      You should not make any assumptions about the meaning of the bits in a process serial number. To compare two process serial numbers, you should use the function SameProcess.

      You can obtain a process serial number in one of the following ways:

      Process serial numbers are returned by the functions LaunchApplication, GetCurrentProcess, and GetFrontProcess.

      Some high-level events return process serial numbers.

I was trying to open a test text file (text.xyz) with my SimpleEditor application by double-clicking on the file which I'd uploaded to a web server and then downloaded again. The original would open, but the downloaded copy returned the infamous "Cannot open file: -psm_0_xxxxxx" message. This was resolved with:

 xattr -d com.apple.quarantine test.xyz

So, that what psm stands for and what caused it in this instance.

 

TinyPortal © 2005-2018