App crash on android upgrade to Delphi 11.1

Home Forums kbmMW App crash on android upgrade to Delphi 11.1

Viewing 2 reply threads
  • Author
    Posts
    • #56378
      TomYU
      Participant

      Upgrade to Delphi 11.1 and crash when running app on Android platform after using kbmmw。

      1.create fmx project

      2. uses kbmMWlog

      3.run on android

      4.crash!!!

       

      kbmMW 5.18 and kbmMW 5.19

       

       

       

      • This topic was modified 3 years, 8 months ago by TomYU.
      • This topic was modified 3 years, 8 months ago by TomYU.
    • #56402
      kimbomadsen
      Keymaster

      Hi,

      Thank you for the report. I will have a look at it….

      /Kim

    • #56412
      TomYU
      Participant

      I found the cause of this problem, but I don’t know how to modify the code.

      Problems caused by kbmMWGetCurrentThreadID function on Android platform.

      This function generates an exception when the boundary check compilation option is turned on.

      I recorded more details here:

      https://www.cnblogs.com/kinglandsoft/p/16094998.html

      • #56502
        kimbomadsen
        Keymaster

        Hi,

        Try to open kbmMWCore.pas, locate kbmMWGetCurrentThreadID and change its return value type to TkbmNativeUInt instead of TkbmNativeInt. Then recompile and check if your application works then.
        Please report result back to me.

        /Kim/C4D

        • #56512
          TomYU
          Participant

          it’s work fine.

           

          • #56514
            kimbomadsen
            Keymaster

            Thank you. It is changed in next release.
            /Kim/C4D

          • #56527
            TomYU
            Participant

            Sorry,this is error.

            Define in unit System:

            {$IFDEF POSIX}
            TThreadID = NativeUInt;
            {$ENDIF}

            Help file:

            Defines a platform-dependent unsigned integer.

            NativeUInt represents a subset of the natural numbers. The range of NativeUInt depends on the current platform. On 32-bit platforms, NativeUInt is equivalent to the Cardinal type. On 64-bit platforms, NativeUInt is equivalent to the UInt64 type.

            The size of NativeUInt is equivalent to the size of the pointer on the current platform.

            function kbmMWGetCurrentThreadID:TkbmNativeUInt;
            should change to :
            function kbmMWGetCurrentThreadID:TThreadID ;

          • #56529
            TomYU
            Participant

            This content is meaningless. Kbmmw is right.

Viewing 2 reply threads
  • You must be logged in to reply to this topic.