2 * Copyright 2000, International Business Machines Corporation and others.
5 * This software has been released under the terms of the IBM Public
6 * License. For details, see the LICENSE file in the top-level source
7 * directory or online at http://www.openafs.org/dl/license10.html
10 /* Copyright (C) 1994 Cazamar Systems, Inc. */
12 #include <afs/param.h>
23 void osi_LongToUID(long inval, UUID *outuidp)
25 /* generic UUID whose seconds field we'll never use again */
26 UUID genericCazamarUUID = { /* 7C45E3F8-5F73-101B-89A3-204C4F4F5020 */
30 {0x89, 0xa3, 0x20, 0x4C, 0x4F, 0x4F, 0x50, 0x20}
33 genericCazamarUUID.Data1 = inval;
34 memcpy(outuidp, &genericCazamarUUID, sizeof(UUID));
37 /* compare two UIDs in the dictionary ordering */
38 int osi_UIDCmp(UUID *uid1p, UUID *uid2p)
46 if (uid1p->Data1 < uid2p->Data1) return -1;
47 else if (uid1p->Data1 > uid2p->Data1) return 1;
49 if (uid1p->Data2 < uid2p->Data2) return -1;
50 else if (uid1p->Data2 > uid2p->Data2) return 1;
52 if (uid1p->Data3 < uid2p->Data3) return -1;
53 else if (uid1p->Data3 > uid2p->Data3) return 1;
61 if (v1 < v2) return -1;
62 else if (v1 > v2) return 1;
67 void * __RPC_API MIDL_user_allocate(size_t size)
69 return (void *) malloc(size);
72 void __RPC_API MIDL_user_free(void *p)