(kadm5_s_get_principal): always return an error if the principal
wasn't found. git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@5301 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 1997 Kungliga Tekniska H<>gskolan
|
* Copyright (c) 1997, 1998, 1999 Kungliga Tekniska H<>gskolan
|
||||||
* (Royal Institute of Technology, Stockholm, Sweden).
|
* (Royal Institute of Technology, Stockholm, Sweden).
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
*
|
*
|
||||||
@@ -56,10 +56,9 @@ kadm5_s_get_principal(void *server_handle,
|
|||||||
return ret;
|
return ret;
|
||||||
ret = context->db->fetch(context->context, context->db, &ent);
|
ret = context->db->fetch(context->context, context->db, &ent);
|
||||||
context->db->close(context->context, context->db);
|
context->db->close(context->context, context->db);
|
||||||
if(ret == HDB_ERR_NOENTRY)
|
if(ret)
|
||||||
return _kadm5_error_code(ret);
|
return _kadm5_error_code(ret);
|
||||||
|
|
||||||
|
|
||||||
memset(out, 0, sizeof(*out));
|
memset(out, 0, sizeof(*out));
|
||||||
if(mask & KADM5_PRINCIPAL)
|
if(mask & KADM5_PRINCIPAL)
|
||||||
ret = krb5_copy_principal(context->context, ent.principal,
|
ret = krb5_copy_principal(context->context, ent.principal,
|
||||||
|
Reference in New Issue
Block a user