× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: RE: Retrieve program stack
  • From: "Leland, David" <dleland@xxxxxxxxxx>
  • Date: Mon, 7 Aug 2000 15:05:40 -0500

Title: RE: Retrieve program stack

Terrific!  This will work except for one thing - the LSTJOBSTK allowed for retrieval of any level of the call stack.  This utility only allows you to retrieve the currently running program in the call stack.  Fortunately, this is all we need most of the time.

Dave

-----Original Message-----
From: edfishel@us.ibm.com [mailto:edfishel@us.ibm.com]
Sent: Monday, August 07, 2000 12:43 PM
To: MIDRANGE-L@midrange.com
Subject: Retrieve program stack


Dave,

>We've been using Bryan Leaman's MI program LSTJOBSTK (from the June 1994
>issue of News/400) to retrieve the program stack for a job.  Now, we'd
like
>to move from security level 30 to 40 and can't because this program uses
an
>unsupported interface.  I know that there is another method of retrieving
>the program stack by using program messages but don't like this method
>because it doesn't return the library of the program, only the program
name.
>Does anyone know of a way of retrieving both the programs and libraries in
a
>job's call stack that would be supported at security level 40?

I found the following solution to this problem on comp.sys.ibm.as400.misc
several months ago. I do not remember who the author is. I made a few minor
modifications.

  DCL        VAR(&MSGDTA) TYPE(*CHAR) LEN(20)
  DCL        VAR(&PGM) TYPE(*CHAR) LEN(10)
  DCL        VAR(&PGMLIB) TYPE(*CHAR) LEN(10)

  DLTF       FILE(QTEMP/NOTFOUND)
  MONMSG     MSGID(CPF2105) EXEC(DO)
     RCVMSG     MSGTYPE(*EXCP)
  ENDDO
  OVRDBF     FILE(QPPGMDMP) TOFILE(QTEMP/NOTFOUND)
  DMPCLPGM
  MONMSG     MSGID(CPF0570) EXEC(DO)
     RCVMSG     MSGTYPE(*DIAG)
     RCVMSG     MSGTYPE(*EXCP) MSGDTA(&MSGDTA)
     CHGVAR     VAR(&PGM) VALUE(%SST(&MSGDTA 1 10))
     CHGVAR     VAR(&PGMLIB) VALUE(%SST(&MSGDTA 11 10))
  ENDDO
  DLTOVR     FILE(QPPGMDMP)

Ed Fishel,
edfishel@US.IBM.COM


+---
| This is the Midrange System Mailing List!
| To submit a new message, send your mail to MIDRANGE-L@midrange.com.
| To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com.
| To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.