aboutsummaryrefslogtreecommitdiff
path: root/src/examples/websocket_threaded_example.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/examples/websocket_threaded_example.c')
-rw-r--r--src/examples/websocket_threaded_example.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/examples/websocket_threaded_example.c b/src/examples/websocket_threaded_example.c
index 21f58ed3..e1580548 100644
--- a/src/examples/websocket_threaded_example.c
+++ b/src/examples/websocket_threaded_example.c
@@ -282,7 +282,7 @@ SHA1Result (struct SHA1Context *context, unsigned char
282 } 282 }
283 if (context->corrupted) 283 if (context->corrupted)
284 { 284 {
285 return context->corrupted; 285 return SHA1_RESULT_STATE_ERROR;
286 } 286 }
287 if (! context->computed) 287 if (! context->computed)
288 { 288 {
@@ -319,12 +319,12 @@ SHA1Input (struct SHA1Context *context, const unsigned char *message_array,
319 } 319 }
320 if (context->computed) 320 if (context->computed)
321 { 321 {
322 context->corrupted = SHA1_RESULT_STATE_ERROR; 322 context->corrupted = 1;
323 return SHA1_RESULT_STATE_ERROR; 323 return SHA1_RESULT_STATE_ERROR;
324 } 324 }
325 if (context->corrupted) 325 if (context->corrupted)
326 { 326 {
327 return context->corrupted; 327 return SHA1_RESULT_STATE_ERROR;
328 } 328 }
329 while (length-- && ! context->corrupted) 329 while (length-- && ! context->corrupted)
330 { 330 {