cul_image_props 0.3.1 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -7,12 +7,17 @@ module Exif
7
7
  # Don't throw an exception when given an out of range character.
8
8
  def self.make_string(seq)
9
9
  str = ''
10
- seq.each { |c|
10
+ filter = Proc.new { |c|
11
11
  # Screen out non-printing characters
12
12
  if 32 <= c and c < 256
13
13
  str += c.chr
14
14
  end
15
15
  }
16
+ if seq.is_a? String
17
+ seq.each_byte &filter
18
+ else # must be a byte array, right?
19
+ seq.each &filter
20
+ end
16
21
  # If no printing chars
17
22
  if not str.length == 0
18
23
  return seq
@@ -1,7 +1,7 @@
1
1
  module Cul
2
2
  module Image
3
3
  module Properties
4
- VERSION = "0.3.1"
4
+ VERSION = "0.3.2"
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cul_image_props
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-01-03 00:00:00.000000000 Z
12
+ date: 2013-01-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: nokogiri