Commit d54fb7ab4f6f5ff8bab7ca6b5ad38a493aaa1cd5
1 parent
bbc56d7a
Exists in
master
and in
3 other branches
Storing ssl error popup info directly on windows event log when the
notification is disabled.
Showing
1 changed file
with
23 additions
and
0 deletions
Show diff stats
src/ssl/negotiate.c
@@ -452,6 +452,28 @@ int popup_ssl_error(H3270 *hSession, int rc, const char *title, const char *summ | @@ -452,6 +452,28 @@ int popup_ssl_error(H3270 *hSession, int rc, const char *title, const char *summ | ||
452 | else | 452 | else |
453 | message = lib3270_strdup_printf("rc=%d",rc); | 453 | message = lib3270_strdup_printf("rc=%d",rc); |
454 | 454 | ||
455 | +#ifdef _WIN32 | ||
456 | + | ||
457 | + const char *outMsg[] = { | ||
458 | + title, | ||
459 | + summary, | ||
460 | + message | ||
461 | + }; | ||
462 | + | ||
463 | + ReportEvent( | ||
464 | + hEventLog, | ||
465 | + EVENTLOG_ERROR_TYPE, | ||
466 | + 1, | ||
467 | + 0, | ||
468 | + NULL, | ||
469 | + 3, | ||
470 | + 0, | ||
471 | + outMsg, | ||
472 | + NULL | ||
473 | + ); | ||
474 | + | ||
475 | +#else | ||
476 | + | ||
455 | lib3270_write_log( | 477 | lib3270_write_log( |
456 | hSession, | 478 | hSession, |
457 | "SSL", | 479 | "SSL", |
@@ -461,6 +483,7 @@ int popup_ssl_error(H3270 *hSession, int rc, const char *title, const char *summ | @@ -461,6 +483,7 @@ int popup_ssl_error(H3270 *hSession, int rc, const char *title, const char *summ | ||
461 | message | 483 | message |
462 | ); | 484 | ); |
463 | 485 | ||
486 | +#endif // _WIN32 | ||
464 | 487 | ||
465 | return 0; | 488 | return 0; |
466 | #endif // SSL_ENABLE_NOTIFICATION_WHEN_FAILED | 489 | #endif // SSL_ENABLE_NOTIFICATION_WHEN_FAILED |