summaryrefslogtreecommitdiffstats
path: root/usr.bin/doscmd
diff options
context:
space:
mode:
authoriedowse <iedowse@FreeBSD.org>2001-08-01 10:25:13 +0000
committeriedowse <iedowse@FreeBSD.org>2001-08-01 10:25:13 +0000
commita39dd4a8a2667a356076c964a98d206994042433 (patch)
treec6b4cfdde3833cc33b877f898f5192102f43b2a8 /usr.bin/doscmd
parent783238c99fb9b94143ab761ea6b702787b57a7a0 (diff)
downloadFreeBSD-src-a39dd4a8a2667a356076c964a98d206994042433.zip
FreeBSD-src-a39dd4a8a2667a356076c964a98d206994042433.tar.gz
Fix a client-side memory leak in nfs_flush(). The code allocates
a temporary array to store struct buf pointers if the list doesn't fit in a local array. Usually it frees the array when finished, but if it jumps to the 'again' label and the new list does fit in the local array then it can forget to free a previously malloc'd M_TEMP memory. Move the free() up a line so that it frees any previously allocated memory whether or not it needs to malloc a new array. Reviewed by: dillon
Diffstat (limited to 'usr.bin/doscmd')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud