Fixes deadlock issue for synchronous objectForKey:

Re-implements synchronous objectForKey as true synchronous methods. See http://stackoverflow.com/questions/19306934/trouble-with-dispatch-semaphore-wait-on-some-devices/19325192#19325192 for discussion.