aboutsummaryrefslogtreecommitdiffstats
path: root/src/context.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2014-08-14 15:15:04 +0000
committerWerner Koch <[email protected]>2014-08-17 10:29:16 +0000
commitb6da2da96780ec270439eba5569a618cabe4da02 (patch)
treec60b3258b5318c93df6d369a28c432f430056916 /src/context.c
parentAvoid a vasprintf call if tracing has not been enabled. (diff)
downloadlibassuan-b6da2da96780ec270439eba5569a618cabe4da02.tar.gz
libassuan-b6da2da96780ec270439eba5569a618cabe4da02.zip
Fix possible segv in a call to _assuan_debug.
* src/context.c (assuan_set_error): Do not pass NULL for %s in the trace function. -- This likely fixes GnuPG-bug-id: 1659
Diffstat (limited to 'src/context.c')
-rw-r--r--src/context.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/context.c b/src/context.c
index b4d4d49..62b7f57 100644
--- a/src/context.c
+++ b/src/context.c
@@ -190,7 +190,7 @@ assuan_set_error (assuan_context_t ctx, gpg_error_t err, const char *text)
{
TRACE4 (ctx, ASSUAN_LOG_CTX, "assuan_set_error", ctx,
"err=%i (%s,%s),text=%s", err, gpg_strsource (err),
- gpg_strerror (err), text);
+ gpg_strerror (err), text?text:"(none)");
ctx->err_no = err;
ctx->err_str = text;