Simulators which don't have detailed debugging available on their default
device (usually CPU), automatically have the event debugging options
available. Simulators which have CPU device debugging will have to add
the SIM_DBG_EVENT, SIM_DBG_ACTIVATE and SIM_DBG_AIO_QUEUE to
their debug option list to provide this detailed debugging.
- Use memmove instead of memcpy for potentially overlapping moves.
- Fix memory leaks in error paths.
- Fix potential NULL pointer references
- Assure that string copies stay within bounds of the destination string and
are NUL terminated
- Fix NULL pointer dereferencing in help routines
remove()'s behavior was extended to perform either a unlink() and if
that failed, a rmdir(). This is not consistent with the native commands
del or rm since they only remove a file but not a directory.
This allows a device simulator to specifically name the units that it uses
for different purposes. This info is visible in the output of SHOW QUEUE
and debug output.
Once specified or dynamically determined (as previously occurred with
each call to sim_uname()), that name is saved for fast delivery on subsequent
calls. This will remove some overhead when running with debugging on.
The fprintf substitute function Fprintf can call tmxr_linemsgvf which may
internally produce debug output thus producing an infinite recursion.
All writes to the debug file are now done by explicit calls to fwrite() OR the
Fprintf socket destination is saved and cleared during all calls to fprintf.
Add consistent debug options to track TODR activities and the values which
are set. Debug data will display the VMS time related to the values set and
read.
Added debug CHECK option to the sim_timer_activate_after() to verify
that coscheduled events actually have sim_activate_time_usecs() results
which are consistent with each other.
Additionally, coschedule tick processing now properly counts down
pending coschedule queued activities.