diff options
author | 2015-04-03 14:57:06 -0400 | |
---|---|---|
committer | 2015-04-03 14:57:10 -0400 | |
commit | 2d7eed839bccbacee36f44905bb1a1b8e7437ef9 (patch) | |
tree | d5f035dc74c5143ab59dd56ef450b81db40382b0 /Annex/Init.hs | |
parent | fff817f70ce3c86d873775c0d113b074cc486ff8 (diff) |
init: Improve fifo test to detect NFS systems that support fifos but not well enough for sshcaching.
ssh tries to hard link a fifo, and if not, complains:
muxserver_listen: link mux listener .git/annex/ssh/SHARD1@iabak.archiveteam.org.QK8zOCbtNebI7q54 => .git/annex/ssh/SHARD1@iabak.archiveteam.org: Operation not permitted
Diffstat (limited to 'Annex/Init.hs')
-rw-r--r-- | Annex/Init.hs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Annex/Init.hs b/Annex/Init.hs index 3f27a1172..50f4d8522 100644 --- a/Annex/Init.hs +++ b/Annex/Init.hs @@ -162,13 +162,17 @@ probeFifoSupport = do #else tmp <- fromRepo gitAnnexTmpMiscDir let f = tmp </> "gaprobe" + let f2 = tmp </> "gaprobe2" createAnnexDirectory tmp liftIO $ do nukeFile f + nukeFile f2 ms <- tryIO $ do createNamedPipe f ownerReadMode + createLink f f2 getFileStatus f nukeFile f + nukeFile f2 return $ either (const False) isNamedPipe ms #endif |