Check for extraneous solutions in logarithmic equations (#509)