Bug #3210
Make procedure attributes of deleted TARGET-PROCEDURE and SOURCE-PROCEDURE accessible
Status:
New
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
11/14/2016
Due date:
% Done:
0%
billable:
No
vendor_id:
GCD
case_num:
version_reported:
version_resolved:
reviewer:
production:
No
env_name:
topics:
History
#1 Updated by Hynek Cihlar over 9 years ago
When procedure attributes of deleted TARGET-PROCEDURE and SOURCE-PROCEDURE are accessed native 4GL does not cause an invalid handle error as does for regular non-system procedure handles.
- Delete
TARGET-PROCEDUREthat is not itself aTHIS-PROCEDURE(so that it is immediately made invalid) withDELETE PROCEDURE TARGET-PROCEDURE. VALID-HANDLE(TARGET-PROCEDURE)will returnFALSE.- Read
TARGET-PROCEDURE:NAMEfor example, the procedure name will be returned. - Assign
TARGET-PROCEDUREto a variable of typeHANDLE. - Repeat the above step and read the
NAMEattribute through the variable, this time invalid handle error will be reported.
In P2J for the above case invalid handle error is reported regardless whether NAME is accessed through the system handle or a temp variable.
Note that procedure methods can be invoked without an apparent error, too. For example when TARGET-PROCEDURE:ADD-SUPER-PROCEDURE is called on a deleted handle, the call is dispatched without an error being indicated in ERROR-STATUS.
See uast/delete-source-procedure*.p and uast/delete-target-procedure*.p for the details how to reproduce the case.