projects
/
platform
/
upstream
/
nodejs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
19a6258
)
child_process_uv: fix simple/test-child-process-cwd
author
Ryan Dahl
<ry@tinyclouds.org>
Sun, 31 Jul 2011 23:50:45 +0000
(16:50 -0700)
committer
Ryan Dahl
<ry@tinyclouds.org>
Sun, 31 Jul 2011 23:50:53 +0000
(16:50 -0700)
Makefile
patch
|
blob
|
history
src/process_wrap.cc
patch
|
blob
|
history
diff --git
a/Makefile
b/Makefile
index
5d7248a
..
c574d27
100644
(file)
--- a/
Makefile
+++ b/
Makefile
@@
-237,6
+237,7
@@
UVTEST += simple/test-tls-set-encoding
UVTEST += simple/test-child-process-exit-code
UVTEST += simple/test-child-process-buffering
UVTEST += simple/test-child-process-exec-cwd
+UVTEST += simple/test-child-process-cwd
test-uv: all
diff --git
a/src/process_wrap.cc
b/src/process_wrap.cc
index
9c56b01
..
a26e3b5
100644
(file)
--- a/
src/process_wrap.cc
+++ b/
src/process_wrap.cc
@@
-107,7
+107,9
@@
class ProcessWrap : public HandleWrap {
Local<Value> cwd_v = js_options->Get(String::New("cwd"));
if (!cwd_v.IsEmpty() && cwd_v->IsString()) {
String::Utf8Value cwd(cwd_v->ToString());
- options.cwd = strdup(*cwd);
+ if (cwd.length() > 0) {
+ options.cwd = strdup(*cwd);
+ }
}
// options.env