midi-communications-macos 0.5.1 → 0.5.2

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: 3ced6ec8152e9e24a805d8ceff708fa9a18cf94adb03155569740e3324b8cb6f
4
- data.tar.gz: 99e1fefe52df6117b865c120a3b0463a232d4aabe98f4373d4a5078d960ab802
3
+ metadata.gz: dec1a47f7c81ec4828fa8695ef09ef83c3586316a07c8cd5e48a652eea5bf842
4
+ data.tar.gz: 2559876c550d78febccafb7691dbb85e8c20182d555730f99bc981a9ced2f2f6
5
5
  SHA512:
6
- metadata.gz: a8b42bbe039f2d092d793289655930d050863b8d35dd1e5f3f4aec000a52b6d3e0c444a7e8a0cdb5103f284b8fdb8c8456a2f69e393b04dde54e5d4c867cad82
7
- data.tar.gz: ca248f1723a511940f76c63fb21e87b40d56cac73edf36adcce08847a748fb1493494adfaa238d5b8cd3edf9ad7ee91049d219f787b2c2f8f516395921e459dc
6
+ metadata.gz: ce388009c1752c7babe4cdbf77cebda88bf3324d1b20679dc9b6b518592efc5ed379f183b408062afd86d923c7d59c3ed20494bd477cd6c0d00404d670eb151e
7
+ data.tar.gz: 9a835d96f3091ac79ff3f401dd26ad470c665ccd55df1a202b32c995422f73b140819443192734461791e9189836710622f4f7a66f65ad4a63e797827d789a6e
@@ -175,11 +175,14 @@ module MIDICommunicationsMacOS
175
175
  data = first[:data].to_a
176
176
  messages = []
177
177
  messages << data.slice!(0, first[:length])
178
- (count - 1).times do |i|
178
+ (count - 1).times do
179
179
  length_index = find_next_length_index(data)
180
+
181
+ next unless length_index
182
+
180
183
  message_length = data[length_index]
181
184
 
182
- next if message_length.nil?
185
+ next unless message_length
183
186
 
184
187
  packet_start_index = length_index + 2
185
188
  packet_end_index = packet_start_index + message_length
@@ -209,6 +212,7 @@ module MIDICommunicationsMacOS
209
212
  last_is_zero = false
210
213
  end
211
214
  end
215
+ nil
212
216
  end
213
217
 
214
218
  # Give a message its timestamp and package it in a Hash
@@ -22,5 +22,5 @@ require 'midi-communications-macos/source'
22
22
  require 'midi-communications-macos/destination'
23
23
 
24
24
  module MIDICommunicationsMacOS
25
- VERSION = '0.5.1'.freeze
25
+ VERSION = '0.5.2'.freeze
26
26
  end
@@ -1,7 +1,7 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'midi-communications-macos'
3
- s.version = '0.5.1'
4
- s.date = '2021-11-19'
3
+ s.version = '0.5.2'
4
+ s.date = '2021-11-24'
5
5
  s.summary = 'Realtime MIDI IO with Ruby for OSX'
6
6
  s.description = 'Access the Apple Core MIDI framework API with Ruby.'
7
7
  s.authors = ['Javier Sánchez Yeste']
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: midi-communications-macos
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Javier Sánchez Yeste
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-11-19 00:00:00.000000000 Z
11
+ date: 2021-11-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ffi