瀏覽代碼

Fix SERIAL_ECHO forever bug (#17932)

Jason Smith 5 年之前
父節點
當前提交
209fd2d0cb
沒有連結到貢獻者的電子郵件帳戶。
共有 1 個檔案被更改,包括 14 行新增14 行删除
  1. 14
    14
      Marlin/src/core/serial.h

+ 14
- 14
Marlin/src/core/serial.h 查看文件

@@ -184,13 +184,13 @@ extern uint8_t marlin_debug_flags;
184 184
 #define _SELP_21(a,b,V...) do{ _SEP_2(a,b); _SELP_19(V); }while(0)
185 185
 #define _SELP_22(a,b,V...) do{ _SEP_2(a,b); _SELP_20(V); }while(0)
186 186
 #define _SELP_23(a,b,V...) do{ _SEP_2(a,b); _SELP_21(V); }while(0)
187
-#define _SELP_24(a,b,V...) do{ _SEP_2(a,b); _SELP_22(V); }while(0) // Eat two args, pass the rest up
188
-#define _SELP_25(a,b,V...) do{ _SEP_2(a,b); _SELP_23(V); }while(1) // Eat two args, pass the rest up
189
-#define _SELP_26(a,b,V...) do{ _SEP_2(a,b); _SELP_24(V); }while(2) // Eat two args, pass the rest up
190
-#define _SELP_27(a,b,V...) do{ _SEP_2(a,b); _SELP_25(V); }while(3) // Eat two args, pass the rest up
191
-#define _SELP_28(a,b,V...) do{ _SEP_2(a,b); _SELP_26(V); }while(4) // Eat two args, pass the rest up
192
-#define _SELP_29(a,b,V...) do{ _SEP_2(a,b); _SELP_27(V); }while(5) // Eat two args, pass the rest up
193
-#define _SELP_30(a,b,V...) do{ _SEP_2(a,b); _SELP_28(V); }while(6) // Eat two args, pass the rest up
187
+#define _SELP_24(a,b,V...) do{ _SEP_2(a,b); _SELP_22(V); }while(0)
188
+#define _SELP_25(a,b,V...) do{ _SEP_2(a,b); _SELP_23(V); }while(0)
189
+#define _SELP_26(a,b,V...) do{ _SEP_2(a,b); _SELP_24(V); }while(0)
190
+#define _SELP_27(a,b,V...) do{ _SEP_2(a,b); _SELP_25(V); }while(0)
191
+#define _SELP_28(a,b,V...) do{ _SEP_2(a,b); _SELP_26(V); }while(0)
192
+#define _SELP_29(a,b,V...) do{ _SEP_2(a,b); _SELP_27(V); }while(0)
193
+#define _SELP_30(a,b,V...) do{ _SEP_2(a,b); _SELP_28(V); }while(0) // Eat two args, pass the rest up
194 194
 
195 195
 #define SERIAL_ECHOLNPAIR(V...) _SELP_N(NUM_ARGS(V),V)
196 196
 
@@ -220,13 +220,13 @@ extern uint8_t marlin_debug_flags;
220 220
 #define _SELP_21_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_19_P(V); }while(0)
221 221
 #define _SELP_22_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_20_P(V); }while(0)
222 222
 #define _SELP_23_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_21_P(V); }while(0)
223
-#define _SELP_24_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_22_P(V); }while(0) // Eat two args, pass the rest up
224
-#define _SELP_25_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_23_P(V); }while(1) // Eat two args, pass the rest up
225
-#define _SELP_26_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_24_P(V); }while(2) // Eat two args, pass the rest up
226
-#define _SELP_27_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_25_P(V); }while(3) // Eat two args, pass the rest up
227
-#define _SELP_28_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_26_P(V); }while(4) // Eat two args, pass the rest up
228
-#define _SELP_29_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_27_P(V); }while(5) // Eat two args, pass the rest up
229
-#define _SELP_30_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_28_P(V); }while(6) // Eat two args, pass the rest up
223
+#define _SELP_24_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_22_P(V); }while(0)
224
+#define _SELP_25_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_23_P(V); }while(0)
225
+#define _SELP_26_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_24_P(V); }while(0)
226
+#define _SELP_27_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_25_P(V); }while(0)
227
+#define _SELP_28_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_26_P(V); }while(0)
228
+#define _SELP_29_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_27_P(V); }while(0)
229
+#define _SELP_30_P(a,b,V...) do{ _SEP_2_P(a,b); _SELP_28_P(V); }while(0) // Eat two args, pass the rest up
230 230
 
231 231
 #define SERIAL_ECHOLNPAIR_P(V...) _SELP_N_P(NUM_ARGS(V),V)
232 232
 

Loading…
取消
儲存