Oppolzer - Informatik / Blog


Blog-Hauptseite      Neuester Artikel      Älterer Artikel      Neuerer Artikel      Älterer gleiche Kategorie      Neuerer gleiche Kategorie

PL1-L - Merkwürdige Fehler im Zusammenspiel mit PL/1 und C (ON ERROR)

Subject:

ON ERROR GOTO ... ??

From:

Bernd Oppolzer <bernd.oppolzer@T-ONLINE.DE>

Reply-To:

PL1 (language) discussions <PL1-L@LISTSERV.DARTMOUTH.EDU>

Date:

2012.06.20 22:42:19


Hello PL/1 listers,

we have a problem in one of our batch PL/1 programs. After doing some work, the
program enters a loop, consuming CPU but doing no further useful work. I was
asked to examine the problem. We have several hundred modules around, and it
seems that the problem could be a short on storage condition due to some module
which allocates storage and doesn't free it. But there is no ABEND or DUMP.

I now discovered a module with the following coding in it:

ON ERROR BEGIN;
ON ERROR GOTO ENDE;
... do some error handling,
which can IMO lead to further errors ....
END;

CALL FUNCTION /* which probably leads to an ERROR condition */;
...

ENDE:

ON ERROR BEGIN;
ON ERROR SYSTEM:
... do another kind of error handling ...
END;

This looks pretty strange to me. Can you imagine that this coding leeds to an
endless loop, if there is an ERROR condition, followed by a short on storage
situation?

This is NOT the main routine, but a lower level routine which is dynamically
called.

I asked the co-worker, who is responsible for this, to eliminate the ON ERROR
units from this module, because I would prefer to have an ABEND, so that I can
examine the situation and - maybe - the size and the contents of the storage
areas which lead to the short on storage situation.

Do you have further suggestions to clear the situation?

Kind regards

Bernd

Blog-Hauptseite      Neuester Artikel      Älterer Artikel      Neuerer Artikel      Älterer gleiche Kategorie      Neuerer gleiche Kategorie