summaryrefslogtreecommitdiff
path: root/test/parallel/test-fs-watchfile.js
diff options
context:
space:
mode:
authorSakthipriyan Vairamani <thechargingvolcano@gmail.com>2015-07-09 03:23:48 +0530
committerSakthipriyan Vairamani <thechargingvolcano@gmail.com>2015-08-04 10:21:37 +0530
commitea05e760cdb732f58cfe36da1a8ecafe76adc1ac (patch)
treee7e16e6001977362b1d99729cd1f3eca099f29ac /test/parallel/test-fs-watchfile.js
parent64cf71195c83a2ff06319cf8719ff31058c9ff80 (diff)
downloadandroid-node-v8-ea05e760cdb732f58cfe36da1a8ecafe76adc1ac.tar.gz
android-node-v8-ea05e760cdb732f58cfe36da1a8ecafe76adc1ac.tar.bz2
android-node-v8-ea05e760cdb732f58cfe36da1a8ecafe76adc1ac.zip
repl: don't clobber RegExp.$ properties
In REPL, if we evaluate the `RegExp` object's predefined properties, and if they happen to have the same expression, for example, > RegExp.$1 'RegExp.$1' then doing `eval(RegExp.$1)` would evaluate `RegExp.$1` recursively and eventually throw `RangeError: Maximum call stack size exceeded`. This patch stores the old values of `RegExp`'s predefined proprties in an array and restores them just before the current expression entered by user is evaluated. Fixes: https://github.com/nodejs/io.js/issues/597 PR-URL: https://github.com/nodejs/io.js/pull/2137 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Diffstat (limited to 'test/parallel/test-fs-watchfile.js')
0 files changed, 0 insertions, 0 deletions