rmpd 1.1.3 → 1.1.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -63,7 +63,7 @@ module Rmpd
63
63
  def read_response
64
64
  response = []
65
65
 
66
- while (line = @socket.readline)
66
+ while (line = @socket.readline.force_encoding("UTF-8"))
67
67
  response << line.strip
68
68
  break if END_RE === line
69
69
  end
data/lib/rmpd/response.rb CHANGED
@@ -102,6 +102,7 @@ module Rmpd
102
102
  val = val.to_i if KNOWN_INT_FIELDS.include?(key)
103
103
  val = val.to_f if KNOWN_FLOAT_FIELDS.include?(key)
104
104
  val = send("parse_complex_#{key}", val) if KNOWN_COMPLEX_FIELDS.include?(key.to_s)
105
+ val = val.to_s.encode("UTF-8", {:invalid => :replace, :undef => :replace, :replace => "?"}) if val.is_a?(String)
105
106
  val
106
107
  end
107
108
 
data/lib/rmpd/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Rmpd
2
- VERSION = "1.1.3"
2
+ VERSION = "1.1.4"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rmpd
3
3
  version: !ruby/object:Gem::Version
4
- hash: 21
4
+ hash: 27
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 1
9
- - 3
10
- version: 1.1.3
9
+ - 4
10
+ version: 1.1.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - Eric Wollesen
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2012-10-18 00:00:00 Z
18
+ date: 2013-02-04 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: rspec