I am de-referencing the pointers below. A NULL pointer may lead to a crash if I don't do the checks. The other to check are necessary as I am not sure of the result of NULL - 'a'.