upeksonly: Add default clauses to switch statements
This effectively only annotates the code to make it clear that variables set in the switch are always initialized.
This commit is contained in:
parent
8ba6f4dad2
commit
2f0824ab88
1 changed files with 12 additions and 0 deletions
|
@ -1249,6 +1249,9 @@ loopsm_run_state (FpiSsm *ssm, FpDevice *_dev)
|
||||||
awfsm_1000_run_state,
|
awfsm_1000_run_state,
|
||||||
AWFSM_1000_NUM_STATES);
|
AWFSM_1000_NUM_STATES);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
g_assert_not_reached ();
|
||||||
}
|
}
|
||||||
fpi_ssm_start_subsm (ssm, awfsm);
|
fpi_ssm_start_subsm (ssm, awfsm);
|
||||||
}
|
}
|
||||||
|
@ -1290,6 +1293,9 @@ loopsm_run_state (FpiSsm *ssm, FpDevice *_dev)
|
||||||
capsm_1001_run_state,
|
capsm_1001_run_state,
|
||||||
CAPSM_1001_NUM_STATES);
|
CAPSM_1001_NUM_STATES);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
g_assert_not_reached ();
|
||||||
}
|
}
|
||||||
fpi_ssm_start_subsm (ssm, capsm);
|
fpi_ssm_start_subsm (ssm, capsm);
|
||||||
break;
|
break;
|
||||||
|
@ -1318,6 +1324,9 @@ loopsm_run_state (FpiSsm *ssm, FpDevice *_dev)
|
||||||
deinitsm_1001_run_state,
|
deinitsm_1001_run_state,
|
||||||
DEINITSM_1001_NUM_STATES);
|
DEINITSM_1001_NUM_STATES);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
g_assert_not_reached ();
|
||||||
}
|
}
|
||||||
self->capturing = FALSE;
|
self->capturing = FALSE;
|
||||||
fpi_ssm_start_subsm (ssm, deinitsm);
|
fpi_ssm_start_subsm (ssm, deinitsm);
|
||||||
|
@ -1441,6 +1450,9 @@ dev_activate (FpImageDevice *dev)
|
||||||
ssm = fpi_ssm_new (FP_DEVICE (dev), initsm_1001_run_state,
|
ssm = fpi_ssm_new (FP_DEVICE (dev), initsm_1001_run_state,
|
||||||
INITSM_1001_NUM_STATES);
|
INITSM_1001_NUM_STATES);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
g_assert_not_reached ();
|
||||||
}
|
}
|
||||||
fpi_ssm_start (ssm, initsm_complete);
|
fpi_ssm_start (ssm, initsm_complete);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue