procfs_rb 0.1.0 → 0.1.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 19b629e77fea8aaca91e9508f6699c0a1aaac45b4cc5bd0eb4c15673fe462225
4
- data.tar.gz: 3fafda51d24256ba5dc465ff23faa6619867ef30878d1723bc4c54c750441c01
3
+ metadata.gz: 24477d343b42d8b0edad4d1cb496191e3499d57da61dcb6a324415de80a7d037
4
+ data.tar.gz: 5cffb3cb5e00e6690b14ca8554d57264ef0282000e1e75ce301491adc3a444bb
5
5
  SHA512:
6
- metadata.gz: 29caacfbc2428f324dbbae4c0362f9131e55a2ec6298f5e51d29e5ef38ee64774d22d8bffe4177d1b9f00ea44095548f2cd8a9681aca4f0e73077d3bb0a208ff
7
- data.tar.gz: b15568d0cd9b6282838f9bb07172b1d7084677da80cf4bba4d65271c73840a47756ec39fbb4699e67d60e7ce0918473a2a39aa1d182f8d37104ef4bc0fb8257b
6
+ metadata.gz: 0df252f70c3609e35fce187b0fce843132c8e980e98a58e2b74cc5458b27636525eb39bf78e1c2ecea0ed136150b77f0d3d4fd8790987fed55d7ac004b3b945d
7
+ data.tar.gz: 7669be12189a58a6e0655b7af7522f8aaaad0b268e042f7e699e4834ffab716a2572c1d09f68c1053a38fa7d857a8ce47791468f0e979b821b98d5d23ea617c6
@@ -44,6 +44,7 @@ module ProcFS
44
44
  tx_queue: tx_hex.to_i(16),
45
45
  rx_queue: rx_hex.to_i(16),
46
46
  uid: parts[7].to_i,
47
+ timeout: parts[8].to_i,
47
48
  inode: parts[9].to_i
48
49
  )
49
50
  end
@@ -9,6 +9,8 @@ module ProcFS
9
9
  class TcpSocket
10
10
  include Snapshot
11
11
 
12
+ TCP = 'tcp'
13
+
12
14
  # TCP state constants (from linux/tcp_states.h)
13
15
  STATES = {
14
16
  '01' => :established,
@@ -25,17 +27,20 @@ module ProcFS
25
27
  }.freeze
26
28
 
27
29
  MEMBERS = %i[
30
+ protocol
28
31
  local_address local_port
29
32
  remote_address remote_port
30
33
  connection_state
31
34
  tx_queue rx_queue
32
- uid inode
35
+ uid timeout inode
33
36
  ].freeze
34
37
 
35
38
  attr_reader(*MEMBERS)
36
39
 
37
40
  def initialize(local_address:, local_port:, remote_address:, remote_port:,
38
- connection_state:, tx_queue:, rx_queue:, uid:, inode:)
41
+ connection_state:, tx_queue:, rx_queue:, uid:, timeout:, inode:,
42
+ protocol: TCP)
43
+ @protocol = protocol
39
44
  @local_address = local_address
40
45
  @local_port = local_port
41
46
  @remote_address = remote_address
@@ -44,6 +49,7 @@ module ProcFS
44
49
  @tx_queue = tx_queue
45
50
  @rx_queue = rx_queue
46
51
  @uid = uid
52
+ @timeout = timeout
47
53
  @inode = inode
48
54
 
49
55
  freeze
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ProcfsRb
4
- VERSION = '0.1.0'
4
+ VERSION = '0.1.1'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: procfs_rb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thomas Tych