contrast-agent 4.13.0 → 4.13.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 469e09f0e64dcdb68643154ca601b20b8f61d634789dec642a374d6a51671fec
4
- data.tar.gz: e4053b76ef09eaf13ee1cf09418d5ae50cd5e518b5e69f611c0a22d15a9bcd4d
3
+ metadata.gz: 96cff410085a542c1003dda242268f349bc20f738b82bde70725b695661a79bc
4
+ data.tar.gz: 2a5d703693f697785034df1f602ef0f61241ae16edf11dbd174ad9a8da01b72c
5
5
  SHA512:
6
- metadata.gz: 311a76a16c063b1d3afe09921e82efa59ea6367165d78fb26c833ab1dcf1e0daba2c3a0bf3597651cd86d146f4480004e916bb78842c6d8185f824dc768c204d
7
- data.tar.gz: 3a4c0db4f013ccd0c7427ef01e451fa2d57b9458de7ce2c23df3444f3fcc4c824a7b841d81bf2aa25ecfd378be2afcea3ea57cded948bd350f4c6516a509477e
6
+ metadata.gz: 409632acc3352b7c172a1aa12c9f5de482b5e5c3c0307b0732c48c7b8cf8d56c5ef5a4c039a0c866dd0c1ea31340b21ee8e4bcc0f2c4c4fdea9cd4fffcbaa212
7
+ data.tar.gz: 17b56ee4355a472b637cf1f9059f1bfce01319351713fc3b35e744bc3afad3d4f068cf77dd474032193249cb8f178141d7d7da2aa7b4d2f3a0cc2158e1c55d0c
@@ -3,6 +3,6 @@
3
3
 
4
4
  module Contrast
5
5
  module Agent
6
- VERSION = '4.13.0'
6
+ VERSION = '4.13.1'
7
7
  end
8
8
  end
@@ -55,22 +55,21 @@ module Contrast
55
55
  # So for the MacOS we would use the config directory of the instrumented application.
56
56
  @dir = config_dir if Contrast::Utils::OS.mac?
57
57
  return false if File.file? @dir + file
58
+ return true if touch_marker(@dir, file)
58
59
 
59
- begin
60
- return true if touch @dir, file # rubocop:disable Rails/SkipsModelValidations
61
- rescue Errno::EROFS
62
- # If we don't have permission to write to root directory use config instead
63
- return true if touch config_dir, file # rubocop:disable Rails/SkipsModelValidations
64
- end
60
+ # If we don't have permission to write to root directory use config instead
61
+ touch_marker(config_dir, file)
65
62
  end
66
63
 
67
64
  # Touches .telemetry file
68
65
  #
69
66
  # @return[Boolean] true if success, false if fails
70
- def touch dir, file
67
+ def touch_marker dir, file
71
68
  FileUtils.mkdir_p dir unless Dir.exist? dir
72
69
  FileUtils.touch dir + file
73
70
  File.file? dir + file
71
+ rescue StandardError => _e
72
+ false
74
73
  end
75
74
  end
76
75
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: contrast-agent
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.13.0
4
+ version: 4.13.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - galen.palmer@contrastsecurity.com
@@ -13,7 +13,7 @@ authors:
13
13
  autorequire:
14
14
  bindir: exe
15
15
  cert_chain: []
16
- date: 2021-11-09 00:00:00.000000000 Z
16
+ date: 2021-11-19 00:00:00.000000000 Z
17
17
  dependencies:
18
18
  - !ruby/object:Gem::Dependency
19
19
  name: bundler
@@ -617,20 +617,20 @@ executables:
617
617
  - contrast_service
618
618
  extensions:
619
619
  - ext/cs__common/extconf.rb
620
+ - ext/cs__assess_fiber_track/extconf.rb
620
621
  - ext/cs__os_information/extconf.rb
621
- - ext/cs__assess_regexp/extconf.rb
622
- - ext/cs__assess_string_interpolation26/extconf.rb
623
- - ext/cs__contrast_patch/extconf.rb
624
- - ext/cs__assess_active_record_named/extconf.rb
625
- - ext/cs__assess_module/extconf.rb
626
622
  - ext/cs__assess_array/extconf.rb
623
+ - ext/cs__contrast_patch/extconf.rb
627
624
  - ext/cs__assess_kernel/extconf.rb
628
- - ext/cs__assess_basic_object/extconf.rb
629
- - ext/cs__assess_hash/extconf.rb
630
- - ext/cs__assess_fiber_track/extconf.rb
625
+ - ext/cs__assess_regexp/extconf.rb
631
626
  - ext/cs__assess_marshal_module/extconf.rb
632
- - ext/cs__assess_string/extconf.rb
627
+ - ext/cs__assess_module/extconf.rb
628
+ - ext/cs__assess_hash/extconf.rb
629
+ - ext/cs__assess_active_record_named/extconf.rb
633
630
  - ext/cs__assess_yield_track/extconf.rb
631
+ - ext/cs__assess_string/extconf.rb
632
+ - ext/cs__assess_basic_object/extconf.rb
633
+ - ext/cs__assess_string_interpolation26/extconf.rb
634
634
  extra_rdoc_files: []
635
635
  files:
636
636
  - ".clang-format"