Synchronize with 0.9.7-stable branch