bootsnap 1.1.6 → 1.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/ext/bootsnap/bootsnap.c +3 -3
- data/lib/bootsnap/load_path_cache/store.rb +4 -1
- data/lib/bootsnap/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 58c56b006431cac3c1cf8a8c8c542f76ec6cd7dd
|
4
|
+
data.tar.gz: b71fd217b2aded27b42d582d6a123a80bd6c8747
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 43ce6810dfe1626cb8e9b6213ee197c26123fb98bfd7aaa42b5795a7133349002e86037cea64b94bdf7d1cdc45d42671285ae21693e4c0d25962d5e1dc5b133f
|
7
|
+
data.tar.gz: 22545b119efedef68895f61b3f403b6eedb8e6f4a7152da99fed09d430df7bc7125f1d81d5db9ebb45919958c5a215c5968efc34202aa708d7b8349fdb232768
|
data/CHANGELOG.md
CHANGED
data/ext/bootsnap/bootsnap.c
CHANGED
@@ -476,13 +476,13 @@ atomic_write_cache_file(char * path, struct bs_cache_key * key, VALUE data, char
|
|
476
476
|
strcat(dest, ".tmp.XXXXXX");
|
477
477
|
|
478
478
|
tmp_path = mktemp(template);
|
479
|
-
fd = open(tmp_path, O_WRONLY | O_CREAT,
|
479
|
+
fd = open(tmp_path, O_WRONLY | O_CREAT, 0664);
|
480
480
|
if (fd < 0) {
|
481
|
-
if (mkpath(path,
|
481
|
+
if (mkpath(path, 0775) < 0) {
|
482
482
|
*errno_provenance = (char *)"bs_fetch:atomic_write_cache_file:mkpath";
|
483
483
|
return -1;
|
484
484
|
}
|
485
|
-
fd = open(tmp_path, O_WRONLY | O_CREAT,
|
485
|
+
fd = open(tmp_path, O_WRONLY | O_CREAT, 0664);
|
486
486
|
if (fd < 0) {
|
487
487
|
*errno_provenance = (char *)"bs_fetch:atomic_write_cache_file:open";
|
488
488
|
return -1;
|
@@ -71,8 +71,11 @@ module Bootsnap
|
|
71
71
|
# caches if they read at an inopportune time.
|
72
72
|
tmp = "#{@store_path}.#{Process.pid}.#{(rand * 100000).to_i}.tmp"
|
73
73
|
FileUtils.mkpath(File.dirname(tmp))
|
74
|
-
File
|
74
|
+
exclusive_write = File::Constants::CREAT | File::Constants::EXCL | File::Constants::WRONLY
|
75
|
+
File.binwrite(tmp, MessagePack.dump(@data), mode: exclusive_write)
|
75
76
|
FileUtils.mv(tmp, @store_path)
|
77
|
+
rescue Errno::EEXIST
|
78
|
+
retry
|
76
79
|
end
|
77
80
|
end
|
78
81
|
end
|
data/lib/bootsnap/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bootsnap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Burke Libbey
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-12-
|
11
|
+
date: 2017-12-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|