mini_racer 0.17.0.pre10 → 0.17.0.pre11

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f09948c878aaefbc5e47285a3ee17db34e00de5d72e441cbb4ef45dd15e45f06
4
- data.tar.gz: 95aa4a36b7612535524ff9ef6ca3116bde6dad9aa474c1c4b1af9427c0204969
3
+ metadata.gz: 6851fdd7226dd520cf865af8b60e64b3456a0b0cfd31a22d4f275495c8f42aef
4
+ data.tar.gz: ffd5db728de9571a2b7e7d83348a95b658809d36f869050338c1f5b0a814146b
5
5
  SHA512:
6
- metadata.gz: 76a9a93bcb3bdfc0f7073e6a5501d8c96bd993bb85fe321ac54114154f015c0b0f1e2ba21067f79787831cff604f34e82079913b593dab559f4cb74e54781f17
7
- data.tar.gz: ea1da1f7e66915a147fe614cff9a6de80e2d5a2953eabb0de422c0ad2839db940cc9dbf2c5c642604b03fbd5ab71a6c0fd26e15abb38d4f4652273243a41221f
6
+ metadata.gz: 76e7edac2249f6aa850bd03f1a7d4c353095f4e3f0a89466c83763f945de44ac68881b57d5b784ac7b6391dd467812a7d27eeeba98ba13624f60dbe4e1db70ab
7
+ data.tar.gz: 9519ee4b2601ab14a0a1898518bdcda5f318b66b4b4631d7881c2e83ea656c461cbf3fa38682d8702234e01d1cad7c2358125c9b4689333db686ca7207b27fc0
data/CHANGELOG CHANGED
@@ -1,4 +1,7 @@
1
- - 0.17.0.pr10 - 20-01-2025
1
+ - 0.17.0.pre11 - 21-01-2025
2
+ - Corrected encoding bug with deserialization of strings - Ben Noordhuis
3
+
4
+ - 0.17.0.pre10 - 20-01-2025
2
5
  - Added back support for partially deserialized objects (objects that do not translate across boundaries are returned as Error properties) - Ben Noordhuis
3
6
 
4
7
  - 0.17.0.pre9 - 13-01-2025
@@ -339,13 +339,24 @@ static VALUE str_encode_bang(VALUE v)
339
339
 
340
340
  static void des_string8(void *arg, const uint8_t *s, size_t n)
341
341
  {
342
+ rb_encoding *e;
342
343
  DesCtx *c;
343
344
  VALUE v;
344
345
 
345
346
  c = arg;
346
- v = rb_enc_str_new((char *)s, n, rb_ascii8bit_encoding());
347
- if (c->transcode_latin1)
347
+ if (*c->err)
348
+ return;
349
+ if (c->transcode_latin1) {
350
+ e = rb_enc_find("ISO-8859-1"); // TODO cache?
351
+ if (!e) {
352
+ snprintf(c->err, sizeof(c->err), "no ISO-8859-1 encoding");
353
+ return;
354
+ }
355
+ v = rb_enc_str_new((char *)s, n, e);
348
356
  v = str_encode_bang(v); // cannot fail
357
+ } else {
358
+ v = rb_enc_str_new((char *)s, n, rb_ascii8bit_encoding());
359
+ }
349
360
  put(c, v);
350
361
  }
351
362
 
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MiniRacer
4
- VERSION = "0.17.0.pre10"
4
+ VERSION = "0.17.0.pre11"
5
5
  LIBV8_NODE_VERSION = "~> 22.7.0.4"
6
6
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mini_racer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.17.0.pre10
4
+ version: 0.17.0.pre11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sam Saffron
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-01-19 00:00:00.000000000 Z
11
+ date: 2025-01-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -123,9 +123,9 @@ licenses:
123
123
  - MIT
124
124
  metadata:
125
125
  bug_tracker_uri: https://github.com/discourse/mini_racer/issues
126
- changelog_uri: https://github.com/discourse/mini_racer/blob/v0.17.0.pre10/CHANGELOG
127
- documentation_uri: https://www.rubydoc.info/gems/mini_racer/0.17.0.pre10
128
- source_code_uri: https://github.com/discourse/mini_racer/tree/v0.17.0.pre10
126
+ changelog_uri: https://github.com/discourse/mini_racer/blob/v0.17.0.pre11/CHANGELOG
127
+ documentation_uri: https://www.rubydoc.info/gems/mini_racer/0.17.0.pre11
128
+ source_code_uri: https://github.com/discourse/mini_racer/tree/v0.17.0.pre11
129
129
  post_install_message:
130
130
  rdoc_options: []
131
131
  require_paths: