File tree Expand file tree Collapse file tree 4 files changed +6
-6
lines changed Expand file tree Collapse file tree 4 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ def decoder_stub(state)
44
44
# add 4 number of passes for the space reserved for the key, at the end of the decoder stub
45
45
# (see commented source)
46
46
number_of_passes = state . buf . length +4
47
- raise InvalidPayloadSizeException . new ( "The payload being encoded is too long (#{ state . buf . length } bytes)" ) if number_of_passes > 32766
47
+ raise EncodingError . new ( "The payload being encoded is too long (#{ state . buf . length } bytes)" ) if number_of_passes > 32766
48
48
49
49
# 16-bits not (again, see also commented source)
50
50
reg_14 = ( number_of_passes +1 ) ^0xFFFF
Original file line number Diff line number Diff line change @@ -35,8 +35,8 @@ def decoder_stub(state)
35
35
36
36
# add one xor operation for the key (see comment below)
37
37
number_of_passes = state . buf . length /4 +1
38
- raise InvalidPayloadSizeException . new ( "The payload being encoded is too long (#{ state . buf . length } bytes)" ) if number_of_passes > 10240
39
- raise InvalidPayloadSizeException . new ( "The payload is not padded to 4-bytes (#{ state . buf . length } bytes)" ) if state . buf . length %4 != 0
38
+ raise EncodingError . new ( "The payload being encoded is too long (#{ state . buf . length } bytes)" ) if number_of_passes > 10240
39
+ raise EncodingError . new ( "The payload is not padded to 4-bytes (#{ state . buf . length } bytes)" ) if state . buf . length %4 != 0
40
40
41
41
# 16-bits not (again, see below)
42
42
reg_14 = ( number_of_passes +1 ) ^0xFFFF
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ def decoder_stub(state)
44
44
# add 4 number of passes for the space reserved for the key, at the end of the decoder stub
45
45
# (see commented source)
46
46
number_of_passes = state . buf . length +4
47
- raise InvalidPayloadSizeException . new ( "The payload being encoded is too long (#{ state . buf . length } bytes)" ) if number_of_passes > 32766
47
+ raise EncodingError . new ( "The payload being encoded is too long (#{ state . buf . length } bytes)" ) if number_of_passes > 32766
48
48
49
49
# 16-bits not (again, see also commented source)
50
50
reg_14 = ( number_of_passes +1 ) ^0xFFFF
Original file line number Diff line number Diff line change @@ -35,8 +35,8 @@ def decoder_stub(state)
35
35
36
36
# add one xor operation for the key (see comment below)
37
37
number_of_passes = state . buf . length /4 +1
38
- raise InvalidPayloadSizeException . new ( "The payload being encoded is too long (#{ state . buf . length } bytes)" ) if number_of_passes > 10240
39
- raise InvalidPayloadSizeException . new ( "The payload is not padded to 4-bytes (#{ state . buf . length } bytes)" ) if state . buf . length %4 != 0
38
+ raise EncodingError . new ( "The payload being encoded is too long (#{ state . buf . length } bytes)" ) if number_of_passes > 10240
39
+ raise EncodingError . new ( "The payload is not padded to 4-bytes (#{ state . buf . length } bytes)" ) if state . buf . length %4 != 0
40
40
41
41
# 16-bits not (again, see below)
42
42
reg_14 = ( number_of_passes +1 ) ^0xFFFF
You can’t perform that action at this time.
0 commit comments