Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

repl: fix .load infinite loop caused by shared use of lineEnding RegExp #46742

Merged
merged 12 commits into from Mar 1, 2023

Commits on Feb 27, 2023

  1. repl: fix .load infinite loop caused by shared use of lineEnding RegExp

    Since the lineEnding Regular Expression is declared on the module scope,
    recursive invocations of its `[kTtyWrite]` method share one instance of
    this Regular Expression.
    Since the state of a RegExp is managed by instance,
    alternately calling RegExpPrototypeExec with the same RegExp on
    different strings can lead to the state changing unexpectedly.
    This is the root cause of this infinite loop bug when calling .load on
    javascript files of certain shapes.
    Theo-Steiner committed Feb 27, 2023
    Configuration menu
    Copy the full SHA
    2b0871d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f5c3190 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    a9010dc View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    6797e75 View commit details
    Browse the repository at this point in the history

Commits on Feb 28, 2023

  1. remove magic number from test

    Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
    Theo-Steiner and aduh95 committed Feb 28, 2023
    Configuration menu
    Copy the full SHA
    ba29072 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ced5097 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    24a0fb6 View commit details
    Browse the repository at this point in the history
  4. docs: update comments

    Theo-Steiner committed Feb 28, 2023
    Configuration menu
    Copy the full SHA
    d002103 View commit details
    Browse the repository at this point in the history
  5. chore: make finishing touches on comments

    Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
    Theo-Steiner and aduh95 committed Feb 28, 2023
    Configuration menu
    Copy the full SHA
    1cc6e4e View commit details
    Browse the repository at this point in the history

Commits on Mar 1, 2023

  1. Configuration menu
    Copy the full SHA
    6699359 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    d8d6375 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    3950542 View commit details
    Browse the repository at this point in the history