There is nothing in JCL for calling a program with multiple parameters. Even in 
TSO the CPPL points to a single parameter string, from which the program 
normally relies on parse services to extract positional and keyword parameters. 
only in Unix does the program receive multiple parameters.

It's prudent to validate parameters, but hardly customary. Sturgeon's Law 
applies. The code that I've seen ranges from ghastly to excellent, with most 
somewhere in between, and I can't think of any rule of best practice that 
doesn't get violated.

-- 
Shmuel (Seymour J.) Metz
http://mason.gmu.edu/~smetz3
עַם יִשְׂרָאֵל חַי
נֵ֣צַח יִשְׂרָאֵ֔ל לֹ֥א יְשַׁקֵּ֖ר



________________________________________
From: IBM Mainframe Discussion List <[email protected]> on behalf of 
Paul Gilmartin <[email protected]>
Sent: Monday, May 19, 2025 12:11 AM
To: [email protected] <[email protected]>
Subject: Re: Run python with arguments JCL


External Message: Use Caution


On Mon, 19 May 2025 02:36:47 +0000, Seymour J Metz wrote:

>Yes, which is why IBM provided for controlling long parameters for authorized 
>programs. Too bad they didn't do something similar for AC(0).
>
If a program accepts multiple parameters, should the OS
validate  the length of each?

It's customary (outside IBM) for the called routine to validate
all characteristics of parameters, including their lengths.

It's prudent for a called program to make copies of parameters
lest the caller, carelessly or mischievously, modify them
asynchronously.

--
gil

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN




----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to