From 2c291e994f369cb29da3ab2a4d169e9c669ef20c Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Thu, 2 Aug 2007 17:19:32 +0000 Subject: [PATCH] For bug #187518, handle EISDIR thrown from mkdir when the directory already exists on FreeBSD. (trunk r7544) svn path=/main/branches/2.1.2/; revision=7545 --- pym/portage_util.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pym/portage_util.py b/pym/portage_util.py index d71add57e..8e4a8cb44 100644 --- a/pym/portage_util.py +++ b/pym/portage_util.py @@ -852,7 +852,7 @@ def ensure_dirs(dir_path, *args, **kwargs): created_dir = True except OSError, oe: func_call = "makedirs('%s')" % dir_path - if errno.EEXIST == oe.errno: + if oe.errno in (errno.EEXIST, errno.EISDIR): pass elif oe.errno == errno.EPERM: raise OperationNotPermitted(func_call) -- 2.26.2