vitotai / BrewManiacEsp8266

BrewManiac on ESP8266. Only ESP8266 needed.
155 stars 71 forks source link

Expanded buffer to handle long Wifi SSID names #71

Closed allthepies closed 4 years ago

allthepies commented 4 years ago

For long Wifi SSID names, a 128 byte char buffer was overflowing causing BMEx to crash. This patch increases the buffer length to avoid such crashes.

Other lines have changed due to the code beautifier in my IDE removing trailing spaces etc, these are cosmetic.

allthepies commented 4 years ago

Also includes a fix for the automation panel of the web UI. Currently, the panel does not retain it's x/y position as the jQuery .hide() operation removes all the position attributes. Replaced .hide and .show for the auto-p panel with .css("visibility",....) operators which preserves the x/y position.

vitotai commented 4 years ago

Good finding. However, it's not used in 0.5. here is the preview: https://github.com/vitotai/BrewManiacEsp8266/tree/v050trial

allthepies commented 4 years ago

Good finding. However, it's not used in 0.5. here is the preview: https://github.com/vitotai/BrewManiacEsp8266/tree/v050trial

Nice, I'll try it out!

Worth applying the fix to the 0.4.9 codebase anyway ? Always good to have bugs/issues resolved in the latest version.

allthepies commented 4 years ago

Good finding. However, it's not used in 0.5. here is the preview: https://github.com/vitotai/BrewManiacEsp8266/tree/v050trial

Gave v0.50 a go. The UI files aren't built so it ran with the 0.49 HTML/CSS/JS etc. Browser lost connection a few times and then the ESP crashed. Not sure if that's down to it running with the "old" UI files ?

vitotai commented 4 years ago

please delete the old bm.htm.gz. The html is embedded in the binary, like BrewPiLess. I haven’t cleared up the HTML/js sources, so the sources isn’t available now.

allthepies commented 4 years ago

please delete the old bm.htm.gz. The html is embedded in the binary, like BrewPiLess. I haven’t cleared up the HTML/js sources, so the sources isn’t available now.

OK, that works!