]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
rpcgen: Don't free() a pointer after realloc().
authorJohn Baldwin <jhb@FreeBSD.org>
Mon, 5 Dec 2022 00:31:35 +0000 (16:31 -0800)
committerJohn Baldwin <jhb@FreeBSD.org>
Mon, 5 Dec 2022 00:31:35 +0000 (16:31 -0800)
commitf0b58b190107416e813c5db875034c6cfcede523
treee7bf020c21687049cae65ef0f90916b43414b173
parent8dd8d56d95763ffc914bb729eb27d720cd8ab5eb
rpcgen: Don't free() a pointer after realloc().

A successful realloc() already frees the old pointer.

Reported by: GCC -Wuse-after-free
Reviewed by: brooks, imp, emaste
Differential Revision: https://reviews.freebsd.org/D37540
usr.bin/rpcgen/rpc_main.c