Skip to content

ENOTDIR on spawn exits app #53

@cdaringe

Description

@cdaringe

hello:

currently checkOthers does the following:

function checkOthers( name, callback ) {
    var process = spawn( name, [ '--version' ] ),
        re = browsers[ name ].re,
        data = '';

    process.stdout.on( 'data', function( buf ) {
        data += buf;
    } );

however, the spawn command can fail with ENOTDIR. see node-inspector/node-inspector#807 for more on that (and see this libs failure output). an update to the spawn call as follows solves my issue:

function checkOthers( name, callback ) {
    try {
        var process = spawn( name, [ '--version' ] ),
              re = browsers[ name ].re,
              data = '';
    } catch(err) {
      return callback(err)
    }

thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions