migrateImagesToSwift:  wait a bit to prevent deadlocks

Port #1927 into the upcoming release