mirror of
https://github.com/facebook/sapling.git
synced 2024-10-11 01:07:15 +03:00
094810c520
Summary: This refactors the treemanifest union store initialization code, and fixes a crash introduced in D5560787 if --use_hg_tree_manifest is enabled but the underlying repository does not support treemanifest. This moves the treemanifest initialization code into a new importTreeManifest() helper function, and separates it from parsing the CMD_STARTED response. We now only initialize unionStore_ if FLAGS_use_hg_tree_manifest is enabled and the repository supports treemanifest. Other places in the code now only check if unionStore_ is non-null to see if they should try importing via treemanifest. Splitting importTreeManifest() from the CMD_STARTED response parsing will potentially make things cleaner in the future for using multiple hg_import_helper.py processes. Even if we start multiple of these processes, we only need one instance of the C++ union store, and we don't need to re-initialize the treemanifest separately each time. Reviewed By: bolinfest Differential Revision: D5647203 fbshipit-source-id: 71e14156f1d0ebc0880dd819c5b041b7c1146818 |
||
---|---|---|
.. | ||
HgImportTest.cpp | ||
TARGETS |