Adjust for new constants
.
This commit is contained in:
parent
12985521cf
commit
3d14a9a027
1 changed files with 3 additions and 0 deletions
|
@ -269,6 +269,9 @@ function _readlineSync(options) {
|
||||||
if (!fsB) {
|
if (!fsB) {
|
||||||
fsB = process.binding('fs'); // For raw device path
|
fsB = process.binding('fs'); // For raw device path
|
||||||
constants = process.binding('constants');
|
constants = process.binding('constants');
|
||||||
|
// for v6.3.0+
|
||||||
|
constants = constants && constants.fs && typeof constants.fs.O_RDWR === 'number'
|
||||||
|
? constants.fs : constants;
|
||||||
}
|
}
|
||||||
return fsB;
|
return fsB;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue