1 #pragma ident "%Z%%M% %I% %E% SMI" 2 3 /* 4 * WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING 5 * 6 * Openvision retains the copyright to derivative works of 7 * this source code. Do *NOT* create a derivative of this 8 * source code before consulting with your legal department. 9 * Do *NOT* integrate *ANY* of this source code into another 10 * product before consulting with your legal department. 11 * 12 * For further information, read the top-level Openvision 13 * copyright which is contained in the top-level MIT Kerberos 14 * copyright. 15 * 16 * WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING 17 * 18 */ 19 20 21 /* 22 * Copyright 1993 OpenVision Technologies, Inc., All Rights Reserved 23 * 24 * $Header: /cvs/krbdev/krb5/src/lib/kadm5/srv/svr_misc_free.c,v 1.2 1996/10/18 19:45:53 bjaspan Exp $ 25 * 26 */ 27 28 #if !defined(lint) && !defined(__CODECENTER__) 29 static char *rcsid = "$Header: /cvs/krbdev/krb5/src/lib/kadm5/srv/svr_misc_free.c,v 1.2 1996/10/18 19:45:53 bjaspan Exp $"; 30 #endif 31 #include <kadm5/admin.h> 32 #include <stdlib.h> 33 #include "server_internal.h" 34 35 kadm5_ret_t 36 kadm5_free_principal_ent(void *server_handle, 37 kadm5_principal_ent_t val) 38 { 39 kadm5_server_handle_t handle = server_handle; 40 41 CHECK_HANDLE(server_handle); 42 43 if(val) { 44 if(val->principal) 45 krb5_free_principal(handle->context, val->principal); 46 if(val->mod_name) 47 krb5_free_principal(handle->context, val->mod_name); 48 if(val->policy) 49 free(val->policy); 50 51 /* XXX free key_data and tl_data */ 52 53 if (handle->api_version == KADM5_API_VERSION_1) 54 free(val); 55 } 56 return KADM5_OK; 57 } 58