restart coprocess in raw mode
Restarting a crashing git process could result in filename encoding issues when not in a unicode locale, as the restarted processes's handles were not read in raw mode. Since rawMode is always used when starting a coprocess, didn't bother to parameterise it and just always enable it for simplicity. This commit was sponsored by Jake Vosloo on Patreon.
This commit is contained in:
parent
f08ad2f916
commit
e23028d19b
7 changed files with 21 additions and 19 deletions
|
@ -59,7 +59,7 @@ newtype MkTreeHandle = MkTreeHandle CoProcess.CoProcessHandle
|
|||
withMkTreeHandle :: (MonadIO m, MonadMask m) => Repo -> (MkTreeHandle -> m a) -> m a
|
||||
withMkTreeHandle repo a = bracketIO setup cleanup (a . MkTreeHandle)
|
||||
where
|
||||
setup = CoProcess.rawMode =<< gitCoProcessStart False ps repo
|
||||
setup = gitCoProcessStart False ps repo
|
||||
ps = [Param "mktree", Param "--batch", Param "-z"]
|
||||
cleanup = CoProcess.stop
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue