Fixed bug where an empty vector was being accessed.

The code did not properly check if a vector (idMaps) was empty
before accessing it. Fixed.

Change-Id: Id8724b2f8c47ddbb5e8178523c5b7d72c9eb4914
Merge topic 'fix-smp-contour-bug' into master

16929d48 Fixed bug where an empty vector was being accessed.