Fix logic in assert statement.

Assert that the dimensions match before converting the SimpleITK mask
image to an ITK image object.

Change-Id: Ia563f3db35d12dc74979266708b8296915e82609
Merge topic 'SIMPLEITK-558_RegistrationAddFixedMovingMasks' into next

055ac2d5 Fix logic in assert statement.