summaryrefslogtreecommitdiff
path: root/meta-openbmc-mods/meta-common/recipes-support/boost/boost/0001-Fix-Issue-62.patch
blob: 80dfc272594cacb99b4debdd2eb7cbab8cf4452f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
From 318439af2e77731ae2c3df5e198c1d3e8392d556 Mon Sep 17 00:00:00 2001
From: Simon Ebner <Simon.Ebner@advertima.com>
Date: Fri, 22 Mar 2019 15:27:35 +0100
Subject: [PATCH 1/2] Fix Issue 62

Fixes a leaking pipe. See https://github.com/boostorg/process/issues/62
---
 boost/process/detail/posix/executor.hpp | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/boost/process/detail/posix/executor.hpp b/boost/process/detail/posix/executor.hpp
index 1390a58..8b86ed1 100644
--- a/boost/process/detail/posix/executor.hpp
+++ b/boost/process/detail/posix/executor.hpp
@@ -282,7 +282,10 @@ class executor
                 set_error(std::error_code(err, std::system_category()), "Error read pipe");
         }
         if (count == 0)
+        {
+            ::close(source);
             return  ;
+        }
 
         std::error_code ec(data[0], std::system_category());
         std::string msg(data[1], ' ');
-- 
2.7.4