summaryrefslogtreecommitdiff
path: root/src/Run.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Run.hs')
-rw-r--r--src/Run.hs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Run.hs b/src/Run.hs
index 1a0b981..58df868 100644
--- a/src/Run.hs
+++ b/src/Run.hs
@@ -215,9 +215,9 @@ withDisconnectedUp link inner = do
then inner
else do
local (fmap $ \s -> s { tsDisconnectedUp = S.insert netns $ tsDisconnectedUp s }) $ do
- linkDown link
+ atomicallyWithIO $ linkDown link
x <- inner
- linkUp link
+ atomicallyWithIO $ linkUp link
return x
withDisconnectedBridge :: Link Bridge -> TestRun a -> TestRun a
@@ -228,9 +228,9 @@ withDisconnectedBridge bridge inner = do
then inner
else do
local (fmap $ \s -> s { tsDisconnectedBridge = S.insert netns $ tsDisconnectedBridge s }) $ do
- linkDown bridge
+ atomicallyWithIO $ linkDown bridge
x <- inner
- linkUp bridge
+ atomicallyWithIO $ linkUp bridge
return x
withNodePacketLoss :: Node -> Scientific -> TestRun a -> TestRun a