Przeglądaj źródła

Provide strcmp_P where needed (#18103)

ellensp 5 lat temu
rodzic
commit
9bfdc88e52
No account linked to committer's email address
2 zmienionych plików z 10 dodań i 0 usunięć
  1. 5
    0
      Marlin/src/HAL/LINUX/HAL.h
  2. 5
    0
      Marlin/src/HAL/LPC1768/HAL.h

+ 5
- 0
Marlin/src/HAL/LINUX/HAL.h Wyświetl plik

@@ -106,3 +106,8 @@ inline uint8_t HAL_get_reset_source(void) { return RST_POWER_ON; }
106 106
 FORCE_INLINE static void DELAY_CYCLES(uint64_t x) {
107 107
   Clock::delayCycles(x);
108 108
 }
109
+
110
+// Add strcmp_P if missing
111
+#ifndef strcmp_P
112
+  #define strcmp_P(a, b) strcmp((a), (b))
113
+#endif

+ 5
- 0
Marlin/src/HAL/LPC1768/HAL.h Wyświetl plik

@@ -221,3 +221,8 @@ void set_pwm_duty(const pin_t pin, const uint16_t v, const uint16_t v_size=255,
221 221
 // Reset source
222 222
 void HAL_clear_reset_source(void);
223 223
 uint8_t HAL_get_reset_source(void);
224
+
225
+// Add strcmp_P if missing
226
+#ifndef strcmp_P
227
+  #define strcmp_P(a, b) strcmp((a), (b))
228
+#endif

Ładowanie…
Anuluj
Zapisz