Skip to content

Use mkdirSync in create-pipes#18

Open
darkkelvin wants to merge 1 commit intogvarsanyi:masterfrom
darkkelvin:master
Open

Use mkdirSync in create-pipes#18
darkkelvin wants to merge 1 commit intogvarsanyi:masterfrom
darkkelvin:master

Conversation

@darkkelvin
Copy link
Copy Markdown

Replace mkdir with mkdirSync in create-pipes, so error thrown (e.g. on directory existed) would be properly caught.
Currently on directory collision, the asynchronous mkdir's error would not be caught and sync-exec would erroneously assumed the directory to exist, which could result in various error such as hanging.

I know with execSync inherently in Node 0.12 the wise thing to do is probably to move onto that. But for various reasons I'm currently stuck with Node 0.10 and sync-exec is what I'm using to polyfill execSync.
@gvarsanyi would you help review this PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant