ggated: do not expose stack data in sendfail()

admbugs:	590
Submitted by:	Fabian Keil <fk@fabiankeil.de>
Obtained from:	ElectroBSD
This commit is contained in:
emaste 2018-12-04 15:25:15 +00:00
parent 766b56293a
commit f65517717d

View File

@ -591,6 +591,7 @@ sendfail(int sfd, int error, const char *fmt, ...)
va_list ap;
ssize_t data;
memset(&sinit, 0, sizeof(sinit));
sinit.gs_error = error;
g_gate_swap2n_sinit(&sinit);
data = g_gate_send(sfd, &sinit, sizeof(sinit), 0);