#3656: ghci leaves /tmp/ghc* directory if killed by signal
-----------------------------+----------------------------------------------
Reporter:  vvv               |          Owner:                  
    Type:  bug               |         Status:  new             
Priority:  normal            |      Component:  GHCi            
 Version:  6.10.4            |       Severity:  normal          
Keywords:                    |       Testcase:                  
      Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
-----------------------------+----------------------------------------------
 I was wondering where do numerous /tmp/ghc${PID}_0 directories come
 from. And noticed that they are not removed when I kill (close)
 '*haskell*' Emacs buffer instead of typing ':q' in ghci prompt...

 I've investigated this problem down to ghci: when ghci has an .hs file
 `:load`-ed and is killed with SIGHUP or SIGTERM signal, it leaves
 /tmp/ghc${PID}_0 directory.

 {{{
 $ ls -d /tmp/ghc*
 ls: cannot access /tmp/ghc*: No such file or directory
 $ ghci *.hs &
 [1] 26384
 $ GHCi, version 6.10.4: http://www.haskell.org/ghc/  :? for help
 Loading package ghc-prim ... linking ... done.
 Loading package integer ... linking ... done.
 Loading package base ... linking ... done.
 [1 of 1] Compiling Main             ( proxy-POC.hs, interpreted )
 Ok, modules loaded: Main.
 *Main>
 $ ls -d /tmp/ghc*
 /tmp/ghc26384_0

 [1]+  Stopped                 ghci *.hs
 $ kill -HUP %%

 [1]+  Stopped                 ghci *.hs
 $ ls -d /tmp/ghc*
 /tmp/ghc26384_0
 [1]+  Hangup                  ghci *.hs
 $ ls -d /tmp/ghc*
 /tmp/ghc26384_0
 $ pgrep ghc
 $ ps 26384
   PID TTY      STAT   TIME COMMAND
 }}}

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/3656>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to