On 11/12/24 22:30, ToddAndMargo via perl6-users wrote:
On 11/12/24 22:20, ToddAndMargo via perl6-users wrote:
Hi All,

Windows 11-24H4  Pro

After upgrading to
    RakudoMoar-2024.10.01-win-x86_64-msvc.msi
from
    RakudoMoar-2022.06.01-win-x86_64-msvc.msi

I am throwing this error:

     Internal error: unhandled target type                                                         in method AT- POS at C: \Rakudo\share\perl6\core\sources\E72A080325813175F67842B7D3CC6BFBA617C343   (NativeCall::Types) line 114      in sub postcircumfix:<[ ]> at 'SETTING::'src/core.c/ array_slice.rakumod   line 14                    in sub GetSession at C: \NtUtil\NativeWinUtils.rakumod (NativeWinUtils) line 255                          in block <unit> at CobianWrapper.pl6 line 908


This is NativeWinUtils.rakumod (NativeWinUtils) line 255

244: my $array = nativecast(Pointer[WTS_SESSION_INFOA], $ppSession.deref);

255: if $array[$i].State.EVAL eq 0  {
256:    $Session = $array[$i].SessionId.EVAL;
257:    if not $Debug  { last; }
258:  }


Any idea what this is about?

Many thanks,
-T



Now this is weird.  Thjis is line 908 of CobianWrapper.pl6

908: print "   $IAm\'s session ID is <$SessionID>  API Session ID is <" ~ GetSession() ~ ">\n\n";

And I had the wrong line 225

sub GetWTSEnumerateSession(
    #`{
        C++
        BOOL WTSEnumerateSessionsA(
          [in]  HANDLE             hServer,
          [in]  DWORD              Reserved,
          [in]  DWORD              Version,
          [out] PWTS_SESSION_INFOA *ppSessionInfo,
          [out] DWORD              *pCount
        );
        Returns zero if this function fails.
    }
    DWORD $hServer,                        # [in]  HANDLE
    DWORD $Reserved,                       # [in] always 0
    DWORD $Version,                        # [in] always 1
   Pointer[Pointer] $ppSessionInf is rw,  # [out] see _WTS_SESSION_INFOA and _WTS_CONNECTSTATE_CLASS;
    DWORD $pCount         is rw            # [out] DWORD
    )
225:   is native("Wtsapi32.dll")
    is symbol("WTSEnumerateSessionsA")
    returns DWORD  # If the function fails, the return value is zero.
    { * };




Sorry, not line 225, but line 255.  Same as the original post:

255:  if $array[$i].State.EVAL eq 0  {
          $Session = $array[$i].SessionId.EVAL;
          if not $Debug  { last; }
       }

Reply via email to