websocket-eventmachine-base 1.0.2 → 1.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: a75ada130e34ec2730b2d8571091ce6d97370851
4
+ data.tar.gz: e6e1c3ec4d8b19f62a7b1124d93a103c76f84126
5
+ SHA512:
6
+ metadata.gz: 7e09acc073f641a7d4ae024fa40c86aaf7f3e72d92a7fef213ae31ffe074e9d7e98b665b3caa04153cd5b9f8f201b59eec81d3f280a5ca173cc337e6855a4906
7
+ data.tar.gz: fab4a0281c5369c0555bfa165f0d20707d1b19fe45d340b23e923c62376743e52b95c76997e0d53477e5b9ee6bfc0b650c6310cad5be566928f2159f2c1e9b9b
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.0.3
4
+
5
+ - return proper close codes
6
+
3
7
  ## 1.0.2
4
8
 
5
9
  - fix bug that raised error about mismatch EventMachine constant
@@ -1 +1 @@
1
- require File.expand_path('../websocket/eventmachine/base', __FILE__)
1
+ require 'websocket/eventmachine/base'
@@ -186,7 +186,16 @@ module WebSocket
186
186
  break
187
187
  end
188
188
  end
189
- unbind if @frame.error?
189
+ handle_error(@frame.error) if @frame.error?
190
+ end
191
+
192
+ def handle_error(error)
193
+ error_code = case error
194
+ when :invalid_payload_encoding then 1007
195
+ else 1002
196
+ end
197
+ close(error_code)
198
+ unbind
190
199
  end
191
200
 
192
201
  def handle_closing(data)
@@ -1,7 +1,7 @@
1
1
  module WebSocket
2
2
  module EventMachine
3
3
  class Base
4
- VERSION = '1.0.2'
4
+ VERSION = '1.0.3'
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,62 +1,55 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: websocket-eventmachine-base
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
5
- prerelease:
4
+ version: 1.0.3
6
5
  platform: ruby
7
6
  authors:
8
7
  - Bernard Potocki
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2012-12-21 00:00:00.000000000 Z
11
+ date: 2014-05-03 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: websocket
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
- - - ~>
17
+ - - "~>"
20
18
  - !ruby/object:Gem::Version
21
19
  version: '1.0'
22
20
  type: :runtime
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
- - - ~>
24
+ - - "~>"
28
25
  - !ruby/object:Gem::Version
29
26
  version: '1.0'
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: websocket-native
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
- - - ~>
31
+ - - "~>"
36
32
  - !ruby/object:Gem::Version
37
33
  version: '1.0'
38
34
  type: :runtime
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
- - - ~>
38
+ - - "~>"
44
39
  - !ruby/object:Gem::Version
45
40
  version: '1.0'
46
41
  - !ruby/object:Gem::Dependency
47
42
  name: eventmachine
48
43
  requirement: !ruby/object:Gem::Requirement
49
- none: false
50
44
  requirements:
51
- - - ~>
45
+ - - "~>"
52
46
  - !ruby/object:Gem::Version
53
47
  version: '1.0'
54
48
  type: :runtime
55
49
  prerelease: false
56
50
  version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
51
  requirements:
59
- - - ~>
52
+ - - "~>"
60
53
  - !ruby/object:Gem::Version
61
54
  version: '1.0'
62
55
  description: WebSocket base for Ruby client and server
@@ -66,7 +59,7 @@ executables: []
66
59
  extensions: []
67
60
  extra_rdoc_files: []
68
61
  files:
69
- - .gitignore
62
+ - ".gitignore"
70
63
  - CHANGELOG.md
71
64
  - README.md
72
65
  - Rakefile
@@ -76,26 +69,25 @@ files:
76
69
  - websocket-eventmachine-base.gemspec
77
70
  homepage: http://github.com/imanel/websocket-eventmachine-base
78
71
  licenses: []
72
+ metadata: {}
79
73
  post_install_message:
80
74
  rdoc_options: []
81
75
  require_paths:
82
76
  - lib
83
77
  required_ruby_version: !ruby/object:Gem::Requirement
84
- none: false
85
78
  requirements:
86
- - - ! '>='
79
+ - - ">="
87
80
  - !ruby/object:Gem::Version
88
81
  version: '0'
89
82
  required_rubygems_version: !ruby/object:Gem::Requirement
90
- none: false
91
83
  requirements:
92
- - - ! '>='
84
+ - - ">="
93
85
  - !ruby/object:Gem::Version
94
86
  version: '0'
95
87
  requirements: []
96
88
  rubyforge_project:
97
- rubygems_version: 1.8.24
89
+ rubygems_version: 2.2.2
98
90
  signing_key:
99
- specification_version: 3
91
+ specification_version: 4
100
92
  summary: WebSocket base for Ruby client and server
101
93
  test_files: []