Browse Source

heater_index above its use

Scott Lahteine 9 years ago
parent
commit
b0f198c153
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      Marlin/temperature.cpp

+ 2
- 2
Marlin/temperature.cpp View File

1023
         SERIAL_EOL;
1023
         SERIAL_EOL;
1024
     */
1024
     */
1025
 
1025
 
1026
+    int heater_index = heater_id >= 0 ? heater_id : EXTRUDERS;
1027
+
1026
     // If the target temperature changes, restart
1028
     // If the target temperature changes, restart
1027
     if (tr_target_temperature[heater_index] != target_temperature)
1029
     if (tr_target_temperature[heater_index] != target_temperature)
1028
       *state = TRReset;
1030
       *state = TRReset;
1029
 
1031
 
1030
-    int heater_index = heater_id >= 0 ? heater_id : EXTRUDERS;
1031
-
1032
     switch (*state) {
1032
     switch (*state) {
1033
       case TRReset:
1033
       case TRReset:
1034
         *timer = 0;
1034
         *timer = 0;

Loading…
Cancel
Save