diff options
author | Russ Allbery <rra@stanford.edu> | 2008-01-19 00:37:31 +0000 |
---|---|---|
committer | Russ Allbery <rra@stanford.edu> | 2008-01-19 00:37:31 +0000 |
commit | aa57ab48cc9df24ab756b5651959b36a2d81cad3 (patch) | |
tree | ff27773218cb6d2677032d18f6872dd45493b82a /client/error.c | |
parent | 275cc7eac5d693bffec19884bf37322df59a871c (diff) |
When downloading a keytab to a file that already exists, merge the new
keytab keys into that file rather than moving aside the old keytab and
creating a new keytab with only the new keys.
Also fix get handling in the client for all types other than keytabs.
This isn't visible yet since the server doesn't yet support other types
of objects.
Diffstat (limited to 'client/error.c')
-rw-r--r-- | client/error.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/client/error.c b/client/error.c index e95b284..22e7e5b 100644 --- a/client/error.c +++ b/client/error.c @@ -85,7 +85,7 @@ free_error(krb5_context ctx, const char *msg) ** Report a Kerberos error and exit. */ void -die_krb5(krb5_context ctx, krb5_error_code code, const char *format, ...) +die_krb5(krb5_context ctx, krb5_error_code code, const char *format, ...) { const char *k5_msg = NULL; char *message; @@ -93,10 +93,10 @@ die_krb5(krb5_context ctx, krb5_error_code code, const char *format, ...) k5_msg = get_error(ctx, code); va_start(args, format); - if (xasprintf(&message, format, args) < 0) + if (xvasprintf(&message, format, args) < 0) die("internal error: unable to format error message"); va_end(args); - die("%s: %s\n", message, k5_msg); + die("%s: %s", message, k5_msg); } @@ -104,7 +104,7 @@ die_krb5(krb5_context ctx, krb5_error_code code, const char *format, ...) ** Report a Kerberos error. */ void -warn_krb5(krb5_context ctx, krb5_error_code code, const char *format, ...) +warn_krb5(krb5_context ctx, krb5_error_code code, const char *format, ...) { const char *k5_msg = NULL; char *message; @@ -112,10 +112,10 @@ warn_krb5(krb5_context ctx, krb5_error_code code, const char *format, ...) k5_msg = get_error(ctx, code); va_start(args, format); - if (xasprintf(&message, format, args) < 0) + if (xvasprintf(&message, format, args) < 0) die("internal error: unable to format error message"); va_end(args); - warn("%s: %s\n", message, k5_msg); + warn("%s: %s", message, k5_msg); free(message); free_error(ctx, k5_msg); } |