i have no idea what 'system standard' means, but without a value cwd is what is used, not temp storage.
cwd isn't guaranteed to be writable. e.g. running from a script located on a read-only network mount
even if writable, it may be slow.

i have no idea if `dot` actually needs a writable cwd, but the existing code assured that.

another difference with this change: by specifying $env=array() it previously passed an empty environment, the new code passes along the current environment. depending on how dot behaves, that could be construed as an information leak.

i'm not sure to what extent the cwd or env matter to `dot`, but they are both modified by this change.