+plocate 1.1.22, January 12th, 2024
+
+ - Revert the updatedb change in 1.1.21 that did not open
+ pruned paths; it broke pruning of paths that were not at the root
+ (e.g. /foo/bar, as opposed to /foo). Reported by David Caldwell.
+
+
plocate 1.1.21, January 6th, 2024
- Improve interactions between pruning and bind mount detection
hdr.max_version = 2;
hdr.filename_index_offset_bytes = -1;
hdr.zstd_dictionary_length_bytes = -1;
+ hdr.zstd_dictionary_offset_bytes = -1; // Dictionary offset is not known yet.
hdr.check_visibility = check_visibility;
+ hdr.directory_data_length_bytes = 0;
+ hdr.directory_data_offset_bytes = 0;
+ hdr.next_zstd_dictionary_length_bytes = 0;
+ hdr.next_zstd_dictionary_offset_bytes = 0;
+ hdr.conf_block_length_bytes = 0;
+ hdr.conf_block_offset_bytes = 0;
+
fwrite(&hdr, sizeof(hdr), 1, outfp);
if (dictionary.empty()) {
hdr.zstd_dictionary_length_bytes = dictionary.size();
cdict = ZSTD_createCDict(dictionary.data(), dictionary.size(), /*level=*/6);
}
-
- hdr.directory_data_length_bytes = 0;
- hdr.directory_data_offset_bytes = 0;
- hdr.next_zstd_dictionary_length_bytes = 0;
- hdr.next_zstd_dictionary_offset_bytes = 0;
- hdr.conf_block_length_bytes = 0;
- hdr.conf_block_offset_bytes = 0;
}
DatabaseReceiver *DatabaseBuilder::start_corpus(bool store_dir_times)
-project('plocate', 'cpp', default_options: ['buildtype=debugoptimized','cpp_std=c++17'], version: '1.1.21-pre')
+project('plocate', 'cpp', default_options: ['buildtype=debugoptimized','cpp_std=c++17'], version: '1.1.23-pre')
add_project_arguments('-DGROUPNAME="' + get_option('locategroup') + '"', language: 'cpp')
add_project_arguments('-DUPDATEDB_CONF="/etc/updatedb.conf"', language: 'cpp')
ExecStart=@sbindir@/@updatedb_progname@
LimitNOFILE=131072
IOSchedulingClass=idle
+Nice=19
PrivateTmp=true
PrivateDevices=true
start = steady_clock::now();
if (access("/", R_OK | X_OK)) {
// We can't find anything, no need to bother...
+ close(fd);
return 0;
}
uint64_t matched = scan_all_docids(needles, fd, corpus);
dprintf("Done in %.1f ms, found %" PRId64 " matches.\n",
1e3 * duration<float>(steady_clock::now() - start).count(), matched);
+ close(fd);
return matched;
}
dprintf("Hashtable lookups done after %.1f ms.\n", 1e3 * duration<float>(steady_clock::now() - start).count());
if (should_early_exit) {
+ close(fd);
return 0;
}
}
engine.finish();
if (done) {
+ close(fd);
return 0;
}
dprintf("Intersection done after %.1f ms. Doing final verification and printing:\n",
uint64_t matched = scan_docids(needles, cur_candidates, corpus, &engine);
dprintf("Done in %.1f ms, found %" PRId64 " matches.\n",
1e3 * duration<float>(steady_clock::now() - start).count(), matched);
+ close(fd);
return matched;
}
if (*ptr == ':') {
// Separator.
output->push_back(move(str));
+ str.clear();
++ptr;
continue;
}