projects
/
haskell-directory.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
632e371
)
add notes about the non-thread-localness of the current directory (#4082)
author
Simon Marlow
<marlowsd@gmail.com>
Mon, 4 Apr 2011 07:52:00 +0000
(08:52 +0100)
committer
Simon Marlow
<marlowsd@gmail.com>
Mon, 4 Apr 2011 07:52:00 +0000
(08:52 +0100)
System/Directory.hs
patch
|
blob
|
history
diff --git
a/System/Directory.hs
b/System/Directory.hs
index
d264583
..
6c28eef
100644
(file)
--- a/
System/Directory.hs
+++ b/
System/Directory.hs
@@
-862,6
+862,11
@@
Insufficient resources are available to perform the operation.
* 'UnsupportedOperation'
The operating system has no notion of current directory.
* 'UnsupportedOperation'
The operating system has no notion of current directory.
+Note that in a concurrent program, the current directory is global
+state shared between all threads of the process. When using
+filesystem operations from multiple threads, it is therefore highly
+recommended to use absolute rather than relative `FilePath`s.
+
-}
#ifdef __GLASGOW_HASKELL__
getCurrentDirectory :: IO FilePath
-}
#ifdef __GLASGOW_HASKELL__
getCurrentDirectory :: IO FilePath
@@
-902,6
+907,11
@@
current directory cannot be dynamically changed.
The path refers to an existing non-directory object.
@[ENOTDIR]@
The path refers to an existing non-directory object.
@[ENOTDIR]@
+Note that in a concurrent program, the current directory is global
+state shared between all threads of the process. When using
+filesystem operations from multiple threads, it is therefore highly
+recommended to use absolute rather than relative `FilePath`s.
+
-}
setCurrentDirectory :: FilePath -> IO ()
-}
setCurrentDirectory :: FilePath -> IO ()