RPM Package Manager, CVS Repository
  http://rpm5.org/cvs/
  ____________________________________________________________________________

  Server: rpm5.org                         Name:   Jeff Johnson
  Root:   /v/rpm/cvs                       Email:  [EMAIL PROTECTED]
  Module: rpm                              Date:   12-Oct-2007 19:09:41
  Branch: HEAD                             Handle: 2007101218094000

  Modified files:
    rpm                     CHANGES
    rpm/lib                 rpminstall.c
    rpm/python              rpmts-py.c

  Log:
    - rpm.org: have selinux disabled imply RPMTRANS_FLAG_NOCONTEXTS.

  Summary:
    Revision    Changes     Path
    1.1672      +1  -0      rpm/CHANGES
    1.170       +2  -1      rpm/lib/rpminstall.c
    1.72        +5  -3      rpm/python/rpmts-py.c
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: rpm/CHANGES
  ============================================================================
  $ cvs diff -u -r1.1671 -r1.1672 CHANGES
  --- rpm/CHANGES       11 Oct 2007 23:50:04 -0000      1.1671
  +++ rpm/CHANGES       12 Oct 2007 17:09:40 -0000      1.1672
  @@ -1,4 +1,5 @@
   4.5 -> 5.0:
  +    - rpm.org: have selinux disabled imply RPMTRANS_FLAG_NOCONTEXTS.
       - jbj: plug --rebuilddb memory leaks. headerGetExtension() est arrive!
       - jbj: fix: set FD_CLOEXEC in Open() and fdDup().
       - jbj: eliminate rpmMessage, rpmlog instead.
  @@ .
  patch -p0 <<'@@ .'
  Index: rpm/lib/rpminstall.c
  ============================================================================
  $ cvs diff -u -r1.169 -r1.170 rpminstall.c
  --- rpm/lib/rpminstall.c      11 Oct 2007 23:50:04 -0000      1.169
  +++ rpm/lib/rpminstall.c      12 Oct 2007 17:09:40 -0000      1.170
  @@ -322,7 +322,8 @@
        ia->transFlags |= RPMTRANS_FLAG_REPACKAGE;
   
       /* Initialize security context patterns (if not already done). */
  -    if (!(ia->transFlags & RPMTRANS_FLAG_NOCONTEXTS)) {
  +    if (rpmtsSELinuxEnabled(ts) && !(ia->transFlags & 
RPMTRANS_FLAG_NOCONTEXTS))
  +    {
        const char *fn = rpmGetPath("%{?_install_file_context_path}", NULL);
   /[EMAIL PROTECTED]@*/
        if (fn != NULL && *fn != '\0')
  @@ .
  patch -p0 <<'@@ .'
  Index: rpm/python/rpmts-py.c
  ============================================================================
  $ cvs diff -u -r1.71 -r1.72 rpmts-py.c
  --- rpm/python/rpmts-py.c     30 Sep 2007 22:38:30 -0000      1.71
  +++ rpm/python/rpmts-py.c     12 Oct 2007 17:09:40 -0000      1.72
  @@ -1221,12 +1221,14 @@
       }
   
       /* Initialize security context patterns (if not already done). */
  -    if (!(rpmtsFlags(s->ts) & RPMTRANS_FLAG_NOCONTEXTS)) {
  -         const char *fn = rpmGetPath("%{?_install_file_context_path}", NULL);
  +    if (rpmtsSELinuxEnabled(s->ts)
  +     && !(rpmtsFlags(s->ts) & RPMTRANS_FLAG_NOCONTEXTS))
  +    {
  +     const char *fn = rpmGetPath("%{?_install_file_context_path}", NULL);
        if (fn != NULL && *fn != '\0')
            rc = matchpathcon_init(fn);
            fn = _free(fn);
  -     }
  +    }
   
   if (_rpmts_debug)
   fprintf(stderr, "*** rpmts_Run(%p) ts %p ignore %x\n", s, s->ts, 
s->ignoreSet);
  @@ .
______________________________________________________________________
RPM Package Manager                                    http://rpm5.org
CVS Sources Repository                                [email protected]

Reply via email to