It's probably a breach of the spirit. I agree w/ the other posters that the matter should have be clarified in advance. B probably should have asked before taking the province, and A should ask for it back before declaring war.
And if B refuses, but happens to find his capital always at >100 unrest due to strange events (hurricanes, blights, etc), well, these things just happen.
