1
0
Fork 0

[DEVOPS-143] Node 12, needs a callback for asynchronous file writes, so switching to synchronous file writes instead

master
Burzlaff, Herbert 2019-10-30 15:08:35 -04:00 committed by Mike Gerwitz
parent 950ae8818b
commit 341aeb6a08
2 changed files with 2 additions and 2 deletions

View File

@ -83,7 +83,7 @@ function _resolvePath( conf_path: string, path: string ): string
*/
function writePidFile( pid_path: string ): void
{
fs.writeFile( pid_path, process.pid );
fs.writeFileSync( pid_path, process.pid );
process.on( 'exit', () => fs.unlink( pid_path ) );
}

View File

@ -116,7 +116,7 @@ module.exports = Class( 'Log',
if ( this._fd !== null )
{
var buffer = new Buffer( sprintf.apply( this, args ) + "\n" );
fs.write( this._fd, buffer, 0, buffer.length, null );
fs.writeSync( this._fd, buffer, 0, buffer.length, null );
}
return this;