apache / couchdb

Seamless multi-master syncing database with an intuitive HTTP/JSON API, designed for reliability
https://couchdb.apache.org/
Apache License 2.0
6.2k stars 1.03k forks source link

Quote QuickJS path #5244

Closed nickva closed 2 weeks ago

nickva commented 2 weeks ago

We used to quote the spawnkiller path like this to handle spaces in paths:

 "\"" ++ filename:join(PrivDir, "couchspawnkillable") ++ "\""

So we stick with the same pattern here as well for QuickJS path.

nickva commented 2 weeks ago

I had forgotten to update the tests. Now I fixed them to use open_port command just like couch_os_proc does, so the test is close to the code we ship. Also, instead of the tests looking through the output I look at the exit code.

https://github.com/apache/couchdb/blob/902d973c3fc9d6c4ab1c3eb5743d517bfbfbb1a7/src/couch/src/couch_os_process.erl#L137