mirror of
https://github.com/NixOS/nix.git
synced 2025-11-26 12:10:59 +01:00
* Fixed very old transactional bug that caused a freeze sometimes
* State components that get their state at runtime can now be (un)installed with nix-env
This commit is contained in:
parent
05297240ea
commit
53a6b9aaa5
20 changed files with 186 additions and 87 deletions
|
|
@ -83,7 +83,7 @@ Derivation getDerivation(const string & fullPath, const Strings & program_args,
|
|||
|
||||
//Retrieve the derivation, there is only 1 drvPath in derivers
|
||||
derivationPath = *(derivers.begin());
|
||||
Derivation drv = derivationFromPath(derivationPath);
|
||||
Derivation drv = derivationFromPathTxn(noTxn, derivationPath);
|
||||
|
||||
if(isStateComponent){
|
||||
DerivationStateOutputs stateOutputs = drv.stateOutputs;
|
||||
|
|
@ -275,7 +275,7 @@ static void revertToRevision(Strings opFlags, Strings opArgs)
|
|||
int timestamp = getTimestamps[statePath];
|
||||
|
||||
//get its derivation-state-items
|
||||
Derivation statePath_drv = derivationFromPath(queryStatePathDrvTxn(noTxn, statePath));
|
||||
Derivation statePath_drv = derivationFromPathTxn(noTxn, queryStatePathDrvTxn(noTxn, statePath));
|
||||
DerivationStateOutputDirs stateOutputDirs = statePath_drv.stateOutputDirs;
|
||||
|
||||
//TODO Sort snapshots??? eg first restore root, then the subdirs??
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue