When prepare_peercred() fails in unix_stream_connect(),
unix_release_sock() is not called for newsk, and the memory
is leaked.
Let's move prepare_peercred() before unix_create1().
Fixes:
|
||
|---|---|---|
| .. | ||
| Kconfig | ||
| Makefile | ||
| af_unix.c | ||
| af_unix.h | ||
| diag.c | ||
| garbage.c | ||
| sysctl_net_unix.c | ||
| unix_bpf.c | ||