Code Monkey home page Code Monkey logo

Comments (5)

mh61503891 avatar mh61503891 commented on June 7, 2024

https://github.com/ironSource/node-regedit/blob/45514bed635114891589abc2c554458417c3b8fc/lib/helper.js#L51

this.push(JSON.parse(chunk))

When chunk including \t, the \t must be escaped with \ according to RFC4627 JSON https://www.ietf.org/rfc/rfc4627.txt, page 4.

Check:

coffee> JSON.parse('["\\t"]')
[ '\t' ]
coffee> JSON.parse('["\t"]')
SyntaxError: Unexpected token   
  at Object.parse (native)
[...]

from node-regedit.

mh61503891 avatar mh61503891 commented on June 7, 2024

https://github.com/ironSource/node-regedit/blob/45514bed635114891589abc2c554458417c3b8fc/vbs/util.vbs#L117

Additional replacement processes to escape extended characters (e.g., tab, backspace, etc.) are needed in Function JsonSafe.

The replacement rule are written in RFC 4627 Section "2.5. Strings" https://www.ietf.org/rfc/rfc4627.txt, page 4.

from node-regedit.

kessler avatar kessler commented on June 7, 2024

Hi @mh61503891

Would you be so kind as to post a small code snippet that replicates this problem so we can work on it?

Thanks

Yaniv

from node-regedit.

kessler avatar kessler commented on June 7, 2024

@mh61503891 bump

from node-regedit.

kessler avatar kessler commented on June 7, 2024

No response from submitting party, closing this issue for now

from node-regedit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.