A corrected solution, using the characteristic polynomial:
For any $A\in S$, all zeros of the characteristic polynomial $f_A$ are real. Assume $A\in B$, so $f_A$ has two positive zeros (or one double zero) and one negative zero. If $A'\in S$ is close enough to $A$, then $f_{A'}$ is close to $f_A$, and since all zeros of $f_{A'}$ are real, their signs must be identical to those of the zeros of $f_A$. Thus $A'$ has the same signature.