Openembedded Bitbake Development
 help / color / mirror / Atom feed
From: "Aníbal Limón" <anibal.limon@linux.intel.com>
To: bitbake-devel@lists.openembedded.org
Subject: [PATCH 1/2] cooker.py: Close lock file and watcher fds when end.
Date: Fri,  3 Jul 2015 15:40:26 -0500	[thread overview]
Message-ID: <1435956027-26996-1-git-send-email-anibal.limon@linux.intel.com> (raw)

When run cooker inside loop it reaches OS max fd's causing
an exception.

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
---
 lib/bb/cooker.py | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lib/bb/cooker.py b/lib/bb/cooker.py
index f31bca6..abe8a52 100644
--- a/lib/bb/cooker.py
+++ b/lib/bb/cooker.py
@@ -1432,6 +1432,9 @@ class BBCooker:
         if self.state in (state.shutdown, state.forceshutdown, state.error):
             if hasattr(self.parser, 'shutdown'):
                 self.parser.shutdown(clean=False, force = True)
+            self.configwatcher.close()
+            self.watcher.close()
+            self.lock.close()
             raise bb.BBHandledException()
 
         if self.state != state.parsing:
-- 
1.9.1



             reply	other threads:[~2015-07-03 20:38 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-03 20:40 Aníbal Limón [this message]
2015-07-03 20:40 ` [PATCH 2/2] tinfoil.py: Add shutdown method Aníbal Limón
2015-07-07 23:12 ` [PATCH 1/2] cooker.py: Close lock file and watcher fds when end Richard Purdie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1435956027-26996-1-git-send-email-anibal.limon@linux.intel.com \
    --to=anibal.limon@linux.intel.com \
    --cc=bitbake-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox