diff --git a/pkg/cgfsmon/public.go b/pkg/cgfsmon/public.go
index 6b590a9..d3b8736 100644
--- a/pkg/cgfsmon/public.go
+++ b/pkg/cgfsmon/public.go
@@ -60,7 +60,7 @@ LOOP:
 	}
 
 	<-ctx.Done()
-	err = ctx.Err()
+	err = context.Cause(ctx)
 	if err != nil {
 		return
 	}
diff --git a/pkg/routeman/public.go b/pkg/routeman/public.go
index 89d0427..f6fa0f5 100644
--- a/pkg/routeman/public.go
+++ b/pkg/routeman/public.go
@@ -49,5 +49,5 @@ func (m *RouteManager) RunRouteManager(ctx context.Context) (err error) {
 	}
 
 	<-ctx.Done()
-	return ctx.Err()
+	return context.Cause(ctx)
 }