auth: Close fd on SetExtendedCellInfo write error 13/14213/2
authorAndrew Deason <adeason@sinenomine.net>
Mon, 18 May 2020 17:09:38 +0000 (12:09 -0500)
committerBenjamin Kaduk <kaduk@mit.edu>
Mon, 18 May 2020 17:57:06 +0000 (13:57 -0400)
commitc81579dc7b0c0ac6bc34f63384d705a4445c2bbd
treedba3cd93433518c14a18baa59bd9336181823256
parent85df3e3d43e033b1c25c33e4a74d4b7b59b567b5
auth: Close fd on SetExtendedCellInfo write error

Currently, and since OpenAFS 1.0, if write() fails here, we leak the
file descriptor. A write() failure should be very unlikely, but close
the fd to make sure we avoid the leak.

Change-Id: I4e8ed4216c4aa5041232fc798a7bc59f6a5570d9
Reviewed-on: https://gerrit.openafs.org/14213
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
src/auth/cellconfig.c