I cannot be positive as there is no dump but think I see the problem. I think you have cleared the PRTDSN field to spaces, not reset it to a valid dataset name…Then asked us to use the value you passed in PRTDSN.
This would cause a dynamic allocation failure for which the ‘Invalid request’ we returned would make sense.
This program is LINKed to and runs in Key 8 so debugging it should not be particularly difficult. I suggest some WTOs placed at strategic locations so you can trace your way through the code.
If you are trying to block other users from using the PRTLIB you could pass a dataset name such as ‘YOU.ARE.NOT.ALLOWED.TO.USE.THE.PRTLIB’. A ‘file not found’ type error would occur when we try to dynamically allocate it but the user should be able to figure out what happened.