Handle os.tmpDir for older versions of node (works in 0.8)