EmotiBit / EmotiBit_FeatherWing

Firmware to run Emotibit with Adafruit feather M0 WiFi and Feather ESP32
MIT License
19 stars 8 forks source link

Add a nullptr check in EmotiBitEda #293

Closed nitin710 closed 4 days ago

nitin710 commented 5 months ago

Calling EmotiBitEda::writeInfoJson(File &jsonFile) crashes MCU if EmotiBitEda::setup is not called in emotibit.setup.

Add a nullptr check in the segment below https://github.com/EmotiBit/EmotiBit_FeatherWing/blob/a63cba341eff8a3320da21e9ee9a9d9ff34b779e/EmotiBitEda.cpp#L548-L549