× 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.



Hello Sam,

Am 25.05.2020 um 19:34 schrieb Sam_L <lennon_s_j@xxxxxxxxxxx>:

Something like this:

d pThing s * inz(*null)
c eval pThing = *null

(Had to think how to do this in fixed format...)

Thanks, compiling/linking was working with the updated statements.

For source and compilation statements of pwgen (and modules), see the savefile at https://leela.pocnet.net/~poc/pwgen.savf

Relevant content of my RPG program:

HCVTOPT(*DATETIME) ALWNULL(*USRCTL)
HOPTION(*NOXREF : *NOSECLVL : *NOSHOWCPY : *NOEXT : *NOSHOWSKP)
H*
D* Imported automatically from the physical file, so not a real statement.
DID S 64A
D*
DPW_BUF S 70A
DPW_SIZE S 10I 0
DPW_FLAGS S 10I 0
DPW_RMVCHR S *
D*
DPW_RAND PR EXTPROC('pw_rand')
D PW_BUF 70A
D PW_SIZE 10I 0 VALUE
D PW_FLAGS 10I 0 VALUE
D PW_RMVCHR *
C*
C MOVE 64 PW_SIZE
C MOVE 3 PW_FLAGS
C EVAL PW_RMVCHR = *NULL
C CALLP PW_RAND ( PW_BUF : PW_SIZE :
C PW_FLAGS : PW_RMVCHR )
C EVAL ID = %str(%addr(PW_BUF))

Compiling module with option 15 in PDM, everything else is default.

Creating the final program with:
CRTPGM PGM(NSUPDATE/DNSUPPG) MODULE(NSUPDATE/DNSUPPG PWGEN/*ALL) ENTMOD(*PGM) ACTGRP(*NEW) DETAIL(*BASIC)

Possibly interesting output from the Linker:

Type Library Object Bound Ident (translation from german headings)
*MODULE NSUPDATE DNSUPPG *YES _QRNP_PEP_DNSUPPG
*MODULE PWGEN PWGEN *YES _C_pep

C-Prototype for the function to be called:
void pw_rand(char *buf, int size, int pw_flags, char *remove)

Could these two listed program entry points possibly harm? Because it's two instead of one? The rest of the RPG program runs fine (as long as I don't call pw_rand).

Calling pw_rand still makes the *PGM crash with MCH3601. Debug Output:

PW_BUF CHAR(70) ' '
VALUE IN HEX '40404040404040404040404040404040404040404040404040404040404040404040404040404040'X
41 '404040404040404040404040404040404040404040404040404040404040'X
PW_FLAGS INT(10) 3 '00000003'X
PW_RMVCHR POINTER SPP:*NULL
PW_SIZE INT(10) 64 '00000040'X

This should fix inconsistencies about Zoned vs. Int and other question marks.

Thanks again @all for your help!

:wq! PoC

PGP-Key: DDD3 4ABF 6413 38DE - https://www.pocnet.net/poc-key.asc



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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.