Skip to content

Commit

Permalink
remove hardcarded formfeed characters
Browse files Browse the repository at this point in the history
  • Loading branch information
emiltin committed Nov 13, 2019
1 parent ce3b0a2 commit c9eaa1e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/rsmp/proxy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def start_reader
@reader = @task.async do |task|
task.annotate "reader"
@stream = Async::IO::Stream.new(@socket)
@protocol = Async::IO::Protocol::Line.new(@stream,"\f") # rsmp messages are json terminated with a form-feed
@protocol = Async::IO::Protocol::Line.new(@stream,RSMP::WRAPPING_DELIMITER) # rsmp messages are json terminated with a form-feed

while json = @protocol.read_line
beginning = Time.now
Expand Down
2 changes: 1 addition & 1 deletion lib/rsmp/supervisor_proxy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def connect
@endpoint = Async::IO::Endpoint.tcp(@ip, @port)
@socket = @endpoint.connect
@stream = Async::IO::Stream.new(@socket)
@protocol = Async::IO::Protocol::Line.new(@stream,"\f") # rsmp messages are json terminated with a form-feed
@protocol = Async::IO::Protocol::Line.new(@stream,RSMP::WRAPPING_DELIMITER) # rsmp messages are json terminated with a form-feed
end

def connection_complete
Expand Down
2 changes: 1 addition & 1 deletion spec/supervisor_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
endpoint = Async::IO::Endpoint.tcp("127.0.0.1", supervisor.supervisor_settings['port'])
socket = endpoint.connect
stream = Async::IO::Stream.new(socket)
protocol = Async::IO::Protocol::Line.new(stream,"\f") # rsmp messages are json terminated with a form-feed
protocol = Async::IO::Protocol::Line.new(stream,RSMP::WRAPPING_DELIMITER) # rsmp messages are json terminated with a form-feed

# write version message
protocol.write_lines '{"mType":"rSMsg","type":"Version","RSMP":[{"vers":"3.1.4"}],"siteId":[{"sId":"RN+SI0001"}],"SXL":"1.1","mId":"8db00f0a-4124-406f-b3f9-ceb0dbe4aeb6"}'
Expand Down

0 comments on commit c9eaa1e

Please sign in to comment.