HomeFreeBSD

Before returning because of an memory allocation error, free the memory

Description

Before returning because of an memory allocation error, free the memory
already allocated to buf.

Found using clang's static analyzer - scan-build

Submitted by: Thomas Rix <trix@juniper.net>
Reviewed by: stevek
Approved by: sjg (mentor)
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D9852

Details

Provenance
stevekAuthored on
Reviewer
stevek
Differential Revision
D9852: Fix a memory leak in ppp
Parents
rS319637: Add testcases for `cat -b`
Branches
Unknown
Tags
Unknown