CRM-13665 - Make upgrade fault tolerant for merging activity contacts

http://issues.civicrm.org/jira/browse/CRM-13665
Merge pull request #1868 from dlobo/CRM-13665

CRM-13665 - Make upgrade fault tolerant for merging activity contacts