The jurisdiction of a court-martial is limited to the trial of persons accused of military offenses as described in the code. Persons subject to the code who are accused of offenses cognizable by the civil courts of this state or any other state where the military forces are present in that state may, upon accusation, be promptly surrendered to civil authorities for disposition, urgencies of the service considered. If the person subject to the code is accused of both a military offense under the code and a civil offense by the civil authorities, he or she shall be released to the civil authorities if the crime for which he or she is accused by the civil authorities carries a penalty in excess of the maximum penalty provided by the code.