aboutsummaryrefslogtreecommitdiffstats
path: root/demos/tunala/sm.c
diff options
context:
space:
mode:
Diffstat (limited to 'demos/tunala/sm.c')
-rw-r--r--demos/tunala/sm.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/demos/tunala/sm.c b/demos/tunala/sm.c
index 05bd7b9459..ee661c5197 100644
--- a/demos/tunala/sm.c
+++ b/demos/tunala/sm.c
@@ -119,7 +119,8 @@ int state_machine_close_clean(state_machine_t *machine)
buffer_close(&machine->clean_in);
buffer_close(&machine->clean_out);
/* And start an SSL shutdown */
- SSL_shutdown(machine->ssl);
+ if(machine->ssl)
+ SSL_shutdown(machine->ssl);
/* This is an "event", so flush the SSL of any generated traffic */
state_machine_churn(machine);
if(buffer_empty(&machine->dirty_in) &&