Negated potential buffer overflow
Fixed backwards debug condition
Fixed backwards bounds check in ide code
Improved erasure_tool