From 0eef6dabc6b6a4e883654c78a0b88cebb6b3d7cd Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Tue, 17 Oct 2006 13:19:55 +0000 Subject: [PATCH] r19372: Fix segfault for ui's that don't support comments. --- source/torture/ui.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/torture/ui.c b/source/torture/ui.c index d8bff6cca3f..beb0e8fa9c8 100644 --- a/source/torture/ui.c +++ b/source/torture/ui.c @@ -49,7 +49,8 @@ void _torture_fail_ext(struct torture_context *context, va_start(ap, fmt); context->last_reason = talloc_vasprintf(context, fmt, ap); /* make sure the reason for the failure is displayed */ - context->ui_ops->comment(context, context->last_reason); + if (context->ui_ops->comment) + context->ui_ops->comment(context, context->last_reason); va_end(ap); context->last_result = TORTURE_FAIL; } -- 2.11.4.GIT