Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Info about caller

5 views
Skip to first unread message

Karl-Heinz Wittemann

unread,
Jun 10, 2009, 8:00:29 AM6/10/09
to
hi folks,

is there any possibility to obtain an information about the program
(name) who called me (when i run as a subroutine or function)?

thanx
heinz


/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
Fon: +49(0)7083 524965
Fax: +49(0)7083 526877
Mobil: +49(0)175 261 21 28
/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to LIST...@VM.MARIST.EDU with the message: INFO TSO-REXX

Hardee, Charles H

unread,
Jun 10, 2009, 8:16:18 AM6/10/09
to
What language? COBOL, C, HLASM, PL/1, REXX, CLIST, the list is long and
varied...

Karl-Heinz Wittemann

unread,
Jun 10, 2009, 8:33:10 AM6/10/09
to
sorry - REXX of course.

/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
Fon: +49(0)7083 524965
Fax: +49(0)7083 526877
Mobil: +49(0)175 261 21 28
/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/

Zitat von "Hardee, Charles H" <Charles...@CA.COM>:

Hardee, Charles H

unread,
Jun 10, 2009, 9:25:25 AM6/10/09
to
Sorry Heinz,
I only asked because I wanted to make sure you were referring to REXX to
REXX as opposed to REXX being called from another language, etc.
Unfortunately, I have never found a method of doing what you want, but I
would love to know myself.
Hopefully someone on the list has found a means of doing this.
Chuck

Igor Miskulin

unread,
Jun 10, 2009, 9:38:38 AM6/10/09
to
Hi,

when calling your rexx program from other rexx program you can send
program name as parameter or you can store it in stack...

Regards, IgorQuoting Karl-Heinz Wittemann <k...@SPGMBH.DE>:

Karl-Heinz Wittemann

unread,
Jun 10, 2009, 10:09:15 AM6/10/09
to
right. the problem is. that I (the subroutine/command/function) can be
called from hundrets of other rexx-programs from a lot of other people
and i am not able to talk to everyone who calls me. therefor i would
like to find out this by myselv, without changing something with parms
and arg().

i am not familiar wir control blocks, but thought, that somewon could
know, if it is possible to get the information by storage() or
something like this.
thanx
heinz

Zitat von Igor Miskulin <ig...@MISKULIN.COM>:

John Bodoh

unread,
Jun 10, 2009, 10:33:23 AM6/10/09
to
I remember a long time ago when working in IBM, there was an internal program called "caller" that allowed your REXX program to gain access to your callers variable pool. It was probably written in assembler. It it could get at your callers variables, I would think it could also get other information such as the name of the program. I don't think the program was ever made public but it demonstrates that getting at caller information is possible.

John

-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-...@VM.MARIST.EDU] On Behalf Of Karl-Heinz Wittemann

Sent: Wednesday, June 10, 2009 10:07 AM
To: TSO-...@VM.MARIST.EDU
Subject: Re: Info about caller

right. the problem is. that I (the subroutine/command/function) can be
called from hundrets of other rexx-programs from a lot of other people
and i am not able to talk to everyone who calls me. therefor i would
like to find out this by myselv, without changing something with parms
and arg().

i am not familiar wir control blocks, but thought, that somewon could
know, if it is possible to get the information by storage() or
something like this.
thanx
heinz

Zitat von Igor Miskulin <ig...@MISKULIN.COM>:

----------------------------------------------------------------------

Paul Gilmartin

unread,
Jun 10, 2009, 10:43:44 AM6/10/09
to
On Jun 10, 2009, at 08:33, John Bodoh wrote:

> I remember a long time ago when working in IBM, there was an
> internal program called "caller" that allowed your REXX program to
> gain access to your callers variable pool. It was probably written
> in assembler. It it could get at your callers variables, I would
> think it could also get other information such as the name of the
> program. I don't think the program was ever made public but it
> demonstrates that getting at caller information is possible.
>

(OT) In CMS Pipelines this is a builtin facility.

--gil

jim harrison

unread,
Jun 11, 2009, 4:47:44 PM6/11/09
to
IIRC, CLIST has something builtin too - a system variable I think. Been
so long I can't remember what it was.

Rick Woods

unread,
Jun 11, 2009, 6:05:11 PM6/11/09
to
That's what I was thinking too; but I just looked and didn't find it.
- Rick

>>> "jim harrison" <jimh_l...@VERIZON.NET> 6/11/2009 1:46 PM >>>

Marc V Irvin

unread,
Jun 12, 2009, 3:52:47 AM6/12/09
to
Its been done, remember once coding it for a client.

SUBROUTINEs maybe not, FUNCTIONs probably, and CALLs for sure.

Any time a command is entered via TSO command line it goes in a storage location that can be accessed off the CVT. I used to get the information by scanning the most recent command line buffer. I do not really remember the details now, and when I looked for some sample code I could not find it. I think I originally discovered it by just looking at dump. I have programs that look at storage locations via pointer walking, so I would think it should be easy to display it once the rules for finding the command workarea is known.

That a Data Areas manual thing. Or better just take a dump from a called REXX command and see what's up.

Marc Irvin
Analyst Admin, IT Security
Pitney Bowes
PB Internal: 8-421-3422 | External: (203) 739-3422 | Mobile (USA): +1 203 820-3013

Marc V Irvin

unread,
Jun 12, 2009, 4:02:35 AM6/12/09
to
Belay prior email. Foot in mouth. I should be sleep at 4am. I never was able to solve the problem efficiently even with Register 14 13 trace backs. What workarea only gave was the name of the program executing. I have had subroutines where that info was important, and I would want to know the host program name. But I remember now that the name was unreliable because of the many different ways you can invoke REXX commands.

John Bodoh

unread,
Jun 12, 2009, 9:31:10 AM6/12/09
to
Way, way down deep in my memory I seem to remember that when a function
(assembler) is invoked, one of the parameters is an ECT (I think) or
something and that these are linked together. By following the link you can
get to the environment of the REXX caller. Then, by passing that ECT to the
REXX variable access routine, you get your callers variables.\

John

-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-...@VM.MARIST.EDU] On Behalf Of

Marc V Irvin
Sent: Friday, June 12, 2009 3:51 AM
To: TSO-...@VM.MARIST.EDU
Subject: Re: Info about caller

0 new messages