~ubuntu-branches/ubuntu/raring/nss/raring-security

« back to all changes in this revision

Viewing changes to mozilla/security/coreconf/nsinstall/nsinstall.c

  • Committer: Bazaar Package Importer
  • Author(s): Chris Coulson
  • Date: 2010-03-25 13:46:06 UTC
  • mfrom: (1.1.11 upstream)
  • Revision ID: james.westby@ubuntu.com-20100325134606-bl6liuok2w9l7snv
Tags: 3.12.6-0ubuntu1
* New upstream release 3.12.6 RTM (NSS_3_12_6_RTM)
  - fixes CVE-2009-3555 aka US-CERT VU#120541
* Adjust patches to changed upstream code base
  - update debian/patches/38_kbsd.patch
  - update debian/patches/38_mips64_build.patch
  - update debian/patches/85_security_load.patch
* Remove patches that are merged upstream
  - delete debian/patches/91_nonexec_stack.patch
  - update debian/patches/series
* Bump nspr dependency to 4.8
  - update debian/control
* Add new symbols for 3.12.6
  - update debian/libnss3-1d.symbols

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
 
59
59
#define HAVE_LCHOWN
60
60
 
61
 
#if defined(AIX) || defined(BSDI) || defined(HPUX) || defined(LINUX) || defined(SUNOS4) || defined(SCO) || defined(UNIXWARE) || defined(VMS) || defined(NTO) || defined(DARWIN) || defined(BEOS) || defined(__riscos__)
 
61
#if defined(AIX) || defined(BSDI) || defined(HPUX) || defined(LINUX) || defined(SUNOS4) || defined(SCO) || defined(UNIXWARE) || defined(NTO) || defined(DARWIN) || defined(BEOS) || defined(__riscos__)
62
62
#undef HAVE_LCHOWN
63
63
#endif
64
64
 
407
407
 
408
408
            if (ftruncate(tofd, sb.st_size) < 0)
409
409
                fail("cannot truncate %s", toname);
410
 
            /*
411
 
            ** On OpenVMS we can't chmod() until the file is closed, and we
412
 
            ** have to utime() last since fchown/chmod alter the timestamps.
413
 
            */
414
 
#ifndef VMS
415
410
            if (dotimes) {
416
411
                utb.actime = sb.st_atime;
417
412
                utb.modtime = sb.st_mtime;
424
419
            if (chmod(toname, mode) < 0)
425
420
#endif
426
421
                fail("cannot change mode of %s", toname);
427
 
#endif
 
422
 
428
423
            if ((owner || group) && fchown(tofd, uid, gid) < 0)
429
424
                fail("cannot change owner of %s", toname);
430
425
 
432
427
            if (close(tofd) < 0)
433
428
                fail("close reports write error on %s", toname);
434
429
            close(fromfd);
435
 
#ifdef VMS
436
 
            if (chmod(toname, mode) < 0)
437
 
                fail("cannot change mode of %s", toname);
438
 
            if (dotimes) {
439
 
                utb.actime = sb.st_atime;
440
 
                utb.modtime = sb.st_mtime;
441
 
                if (utime(toname, &utb) < 0)
442
 
                    fail("cannot set times of %s", toname);
443
 
            }
444
 
#endif
445
430
        }
446
431
 
447
432
        free(toname);