base: Context has to be opt. in for error functions

This is needed so that it can be optional for path token expansion,
which has to have the context be optional for ccapi (lib/krb5/acache.c),
which in some cases calls path token expansion functions w/ a NULL
context.
This commit is contained in:
Nicolas Williams
2022-01-19 23:30:55 -06:00
parent c650e37321
commit 82e00128a2

View File

@@ -55,7 +55,8 @@ heim_set_error_message(heim_context context, heim_error_code ret,
va_list ap;
va_start(ap, fmt);
heim_vset_error_message(context, ret, fmt, ap);
if (context)
heim_vset_error_message(context, ret, fmt, ap);
va_end(ap);
}