Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Phil Blundell <pb@pbcl.net>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH] package.bbclass: Remove redundant chmod/chown operations
Date: Thu, 02 May 2013 14:20:09 +0100	[thread overview]
Message-ID: <1367500809.14512.252.camel@phil-desktop.brightsign> (raw)

These were introduced in 6021e309e69d823e1467648aee12a32182945569.  The
code currently reads:

                os.link(file, fpath)
                fstat = cpath.stat(file)
                os.chmod(fpath, fstat.st_mode)
                os.chown(fpath, fstat.st_uid, fstat.st_gid)

which can have no useful effect since, if "fpath" is a hard link to
"file", it will (by definition) have the same mode, uid and gid.

Signed-off-by: Phil Blundell <philb@gnu.org>
---
 meta/classes/package.bbclass |    3 ---
 1 file changed, 3 deletions(-)

diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 4136a9f..99eda77 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -1000,9 +1000,6 @@ python populate_packages () {
             fpath = os.path.join(root,file)
             if not cpath.islink(file):
                 os.link(file, fpath)
-                fstat = cpath.stat(file)
-                os.chmod(fpath, fstat.st_mode)
-                os.chown(fpath, fstat.st_uid, fstat.st_gid)
                 continue
             ret = bb.utils.copyfile(file, fpath)
             if ret is False or ret == 0:
-- 
1.7.10.4






             reply	other threads:[~2013-05-02 13:38 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-02 13:20 Phil Blundell [this message]
2013-05-02 13:41 ` [PATCH] package.bbclass: Remove redundant chmod/chown operations Mark Hatle
2013-05-03 14:25   ` Phil Blundell

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=1367500809.14512.252.camel@phil-desktop.brightsign \
    --to=pb@pbcl.net \
    --cc=openembedded-core@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