diff options
author | Simon Josefsson <simon@josefsson.org> | 2010-05-03 15:19:30 +0200 |
---|---|---|
committer | Simon Josefsson <simon@josefsson.org> | 2010-05-03 15:19:30 +0200 |
commit | 199a7ff4d57af9e230441b31a1be7330ba347a49 (patch) | |
tree | 43e7374f28da359a383a4d7304ec847f5696c9a0 /tests/mini-x509.c | |
parent | a182e618ec70d9ed34b706c0c2b900d8a525d23e (diff) | |
download | gnutls-199a7ff4d57af9e230441b31a1be7330ba347a49.tar.gz |
Protect against infloops.
Diffstat (limited to 'tests/mini-x509.c')
-rw-r--r-- | tests/mini-x509.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/mini-x509.c b/tests/mini-x509.c index 0d411a3415..40178d2a59 100644 --- a/tests/mini-x509.c +++ b/tests/mini-x509.c @@ -191,6 +191,10 @@ main (int argc, char *argv[]) do { + static int max_iter = 0; + if (max_iter++ > 10) + abort (); + if (cret == GNUTLS_E_AGAIN) { cret = gnutls_handshake (client); |