It would be very convenient if dmtcp own exit codes could be customized. dmtcp_checkpoint and dmtcp_restart seem to return the application's exit code upon termination, which is excellent. However, when dmtcp_restart fails, e.g., because a file has to be removed manually, it returns with exit code 1. Most applications already use exit code 1, so it is not possible to distinguish a dmtcp exit code from an application exit code to take appropriate action without parsing the error message.
Hence, it would be nice if dmtcp's exit codes could be set using environment variables.