A United Airlines flight out of San Francisco was forced to turn back after a worrying smell was detected in the cabin.