Fixed detection of corrupted flash image

The wrong operator was used: "-ne" is for integers.