Skip to content

Commit 60ec750

Browse files
committed
* Pass --use-atime / --max-atime to the daemon.
1 parent 6f6bb1f commit 60ec750

File tree

3 files changed

+9
-1
lines changed

3 files changed

+9
-1
lines changed

src/libstore/remote-store.cc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -426,6 +426,10 @@ void RemoteStore::collectGarbage(const GCOptions & options, GCResults & results)
426426
writeInt(options.ignoreLiveness, to);
427427
writeLongLong(options.maxFreed, to);
428428
writeInt(options.maxLinks, to);
429+
if (GET_PROTOCOL_MINOR(daemonVersion) >= 5) {
430+
writeInt(options.useAtime, to);
431+
writeInt(options.maxAtime, to);
432+
}
429433

430434
processStderr();
431435

src/libstore/worker-protocol.hh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ namespace nix {
88
#define WORKER_MAGIC_1 0x6e697863
99
#define WORKER_MAGIC_2 0x6478696f
1010

11-
#define PROTOCOL_VERSION 0x104
11+
#define PROTOCOL_VERSION 0x105
1212
#define GET_PROTOCOL_MAJOR(x) ((x) & 0xff00)
1313
#define GET_PROTOCOL_MINOR(x) ((x) & 0x00ff)
1414

src/nix-worker/nix-worker.cc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -452,6 +452,10 @@ static void performOp(unsigned int clientVersion,
452452
options.ignoreLiveness = readInt(from);
453453
options.maxFreed = readLongLong(from);
454454
options.maxLinks = readInt(from);
455+
if (GET_PROTOCOL_MINOR(clientVersion) >= 5) {
456+
options.useAtime = readInt(from);
457+
options.maxAtime = readInt(from);
458+
}
455459

456460
GCResults results;
457461

0 commit comments

Comments
 (0)