On 30.08.2022 18:11, Rick McGuire wrote:


On Tue, Aug 30, 2022 at 11:07 AM Rony G. Flatscher <rony.flatsc...@wu.ac.at> 
wrote:

    While testing a RXMCD exit, implemented in Java and preconfigured for the 
Rexx instance,
    commands trigger the exit, however the DLL information is not supplied, but 
empty (expecting
    "BSF4ooRexx850.dll" as that is the library that contains the callback 
function).  Also, trying
    it with AddCommandEnvironment()-API would not supply the dll name.

        The sequence is: a Java program loads and configures a Rexx instance, 
setting a RXCMD exit
        handler (implemented in Java) and a RexxRedirectingCommandHandler 
(implemented in Java),
        the callback functions are in the native DLL ("BSF4ooRexx850.dll"). 
Both handlers get
        invoked, the RXCMD exit handler does not get a dll name (it is empty).

    In addition, the exit intercepts also commands to CMD, however the dll name 
is empty as well.

    rexxapi.pdf says among other things:

        Example 1.43. API — Rexx_IO_Exit parameter list
        typedef struct {
        struct { /* Condition flags */
            unsigned rxfcfail : 1; /* Command failed. Trap with */
            /* CALL or SIGNAL on FAILURE. */
            unsigned rxfcerr : 1; /* Command ERROR occurred. */
            /* Trap with CALL or SIGNAL on */
            /* ERROR. */
        } rxcmd_flags;
        const char * rxcmd_address; /* Pointer to address name. */
        unsigned short rxcmd_addressl; /* Length of address name. */
        *const char * rxcmd_dll; /* dll name for command. */****unsigned short 
rxcmd_dll_len; /* Length of dll name. 0 ==> */****/* executable file. */*
        CONSTRXSTRING rxcmd_command; /* The command string. */
        RXSTRING rxcmd_retc; /* Pointer to return code */
        /* buffer. User allocated. */
        } RXCMDHST_PARM;

    What does "Length of dll name. 0 ==> executable file" mean, when would that 
take effect? Is
    there anything I need to/can do to get at the DLL-name in the exit?

Nothing, it appears. I don't know what that field was every used for, and from the documentation, it sounds like it was intended for something other than the dll name of the exit. This is born out by the fact that the other exits that can be registered as dlls don't have that field. However, as far back as 3.1.2, it has always been set to null.

Thank you! Maybe we should  add/change a comment to the effect "rxcmd_dll is always set to null" and "rxcmd_dll_len is always set to 0"?

---rony


_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

Reply via email to