(a) Unless otherwise provided in regulations to be prescribed by the Secretary concerned, a court-martial sentence of an enlisted member in pay grade above E-1, as approved by the convening authority, that includes–
(1) a dishonorable or bad-conduct discharge;
(2) confinement; or
(3) hard labor without confinement; reduces that member to pay grade E1, effective on the date of that approval.
(b) If the sentence of a member who is reduced in pay grade under subsection (a) is set aside or disapproved, or, as finally approved does not include any punishment named in subsection (a)(1), (2), or (3), the rights and privileges of which he was deprived because of that reduction shall be restored to him and he is entitled to the pay and allowances to which he would have been entitled for the period the reduction was in effect, had he not been so reduced.