Added missing safety check for visual
Added missing safety check for visual

Checked for pointer being a NULL pointer but actually had to check,
wheather the pointer pointed to a NULL pointer, before dereferncing it
twice.

(Confused visual info pointer with pointer to visual info pointer)

AgentD/sgui,AgentD/sgui,AgentD/sgui