Patches

Also fix #1826 

@emanuele45  please check https://github.com/Spuds/Elkarte/commit/0e92cd28bfc32a1235f511c18c97f41e2d3af6d5 it should fix the overflow issues in many areas