]> git.michaelhowe.org Git - packages/o/openafs.git/commit
SOLARIS: fix for AFS_PAG_ONEGROUP_ENV for Solaris 11
authorMichael Meffie <mmeffie@sinenomine.net>
Thu, 12 Jan 2017 17:27:36 +0000 (12:27 -0500)
committerStephan Wiesand <stephan.wiesand@desy.de>
Wed, 15 Mar 2017 18:05:34 +0000 (14:05 -0400)
commite99fac0e4caf6ddf6c393681a0c9744fa13c9b3e
tree1f47e5657032ef0b949d252fe02f41d7bf548904
parent3457b8965be5e86c820678f6adf1ca45ee440ddc
SOLARIS: fix for AFS_PAG_ONEGROUP_ENV for Solaris 11

Fix a bug introduced in commit aab1e71628e6a4ce68c5e59e2f815867438280d1
in which a pointer was incorrectly checked for a NULL value.

Fixes a crash when a PAG is set on Solaris.

    # mdb unix.1 vmcore.1
    > ::status
    ...
    panic message:
    BAD TRAP: type=e (#pf Page fault) rp=fffffffc802ba8f0 addr=0 occurred in
      module "afs" due to a NULL pointer dereference
    > ::stack
    pag_to_gidset+0x145()
    setpag+0xcc()
    AddPag+0x3a()
    afs_setpag+0x58()
    Afs_syscall+0x115()

The crash occurs since gidslot is NULL during the assignment:

    *gidslot = pagvalue;

Reviewed-on: https://gerrit.openafs.org/12508
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
(cherry picked from commit b146c2d54ff3bd99f2c4674eb88d5af417a194d7)

Change-Id: Ia012d07a3dd063e759a4a50d38e37be710e96255
Reviewed-on: https://gerrit.openafs.org/12527
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
src/afs/SOLARIS/osi_groups.c