diff --git a/hbs2-core/lib/HBS2/Net/Messaging/TCP.hs b/hbs2-core/lib/HBS2/Net/Messaging/TCP.hs index bf19be3f..560ed82d 100644 --- a/hbs2-core/lib/HBS2/Net/Messaging/TCP.hs +++ b/hbs2-core/lib/HBS2/Net/Messaging/TCP.hs @@ -422,10 +422,12 @@ runMessagingTCP env = liftIO do liftIO ( listen (Host (show i)) (show p) $ \(sock, sa) -> do + withFdSocket sock setCloseOnExecIfNeeded debug $ "Listening on" <+> pretty sa forever do void $ acceptFork sock $ \(so, remote) -> do + withFdSocket so setCloseOnExecIfNeeded trace $ "GOT INCOMING CONNECTION FROM" <+> brackets (pretty own) <+> brackets (pretty sa) diff --git a/hbs2-peer/app/PeerMain.hs b/hbs2-peer/app/PeerMain.hs index 9218ff7b..19b34cb0 100644 --- a/hbs2-peer/app/PeerMain.hs +++ b/hbs2-peer/app/PeerMain.hs @@ -267,7 +267,7 @@ runCLI = join . customExecParser (prefs showHelpOnError) $ c <- optional confOpt - resp <- optional $ flag' True ( long "respawn" <> short 'r' <> help "respawn process") + resp <- optional $ flag' True ( long "respawn" <> short 'R' <> help "respawn process") pure $ PeerOpts pref l r k c resp