Revision 391f3b5708cdf8c44e9576f96f79b03eefa95942 authored by Adam Langley on 19 August 2014, 15:57:53 UTC, committed by Emilia Kasper on 22 August 2014, 13:53:14 UTC
Limit the number of empty records that will be processed consecutively in order to prevent ssl3_get_record from never returning. Reported by "oftc_must_be_destroyed" and George Kadianakis. Reviewed-by: Bodo Moeller <bodo@openssl.org> (cherry picked from commit 3aac17a82fbaf2bc23ee62f24611e5883d3e7b97)
1 parent fe9b9a8
dummytest.c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <openssl/e_os2.h>
#include <openssl/buffer.h>
#include <openssl/crypto.h>
int main(int argc, char *argv[])
{
char *p, *q = 0, *program;
p = strrchr(argv[0], '/');
if (!p) p = strrchr(argv[0], '\\');
#ifdef OPENSSL_SYS_VMS
if (!p) p = strrchr(argv[0], ']');
if (p) q = strrchr(p, '>');
if (q) p = q;
if (!p) p = strrchr(argv[0], ':');
q = 0;
#endif
if (p) p++;
if (!p) p = argv[0];
if (p) q = strchr(p, '.');
if (p && !q) q = p + strlen(p);
if (!p)
program = BUF_strdup("(unknown)");
else
{
program = OPENSSL_malloc((q - p) + 1);
strncpy(program, p, q - p);
program[q - p] = '\0';
}
for(p = program; *p; p++)
if (islower((unsigned char)(*p)))
*p = toupper((unsigned char)(*p));
q = strstr(program, "TEST");
if (q > p && q[-1] == '_') q--;
*q = '\0';
printf("No %s support\n", program);
OPENSSL_free(program);
return(0);
}

Computing file changes ...