Print this page
1575 untangle libmlrpc ... (libmlrpc)


  17  * information: Portions Copyright [yyyy] [name of copyright owner]
  18  *
  19  * CDDL HEADER END
  20  */
  21 /*
  22  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23  * Use is subject to license terms.
  24  *
  25  * Copyright 2013 Nexenta Systems, Inc.  All rights reserved.
  26  */
  27 
  28 #include <uuid/uuid.h>
  29 #include <ctype.h>
  30 #include <synch.h>
  31 #include <stdio.h>
  32 #include <unistd.h>
  33 #include <string.h>
  34 #include <strings.h>
  35 #include <assert.h>
  36 
  37 #include <smbsrv/libsmb.h>
  38 #include <smbsrv/libmlrpc.h>
  39 
  40 
  41 /*
  42  * Global list of allocated handles.  Handles are used in various
  43  * server-side RPC functions: typically, issued when a service is
  44  * opened and obsoleted when it is closed.  Clients should treat
  45  * handles as opaque data.
  46  */
  47 static ndr_handle_t *ndr_handle_list;
  48 static mutex_t ndr_handle_lock;
  49 
  50 /*
  51  * Table of registered services.
  52  */
  53 #define NDR_MAX_SERVICES        32
  54 static ndr_service_t *ndr_services[NDR_MAX_SERVICES];
  55 
  56 /*
  57  * Register a service.
  58  *




  17  * information: Portions Copyright [yyyy] [name of copyright owner]
  18  *
  19  * CDDL HEADER END
  20  */
  21 /*
  22  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23  * Use is subject to license terms.
  24  *
  25  * Copyright 2013 Nexenta Systems, Inc.  All rights reserved.
  26  */
  27 
  28 #include <uuid/uuid.h>
  29 #include <ctype.h>
  30 #include <synch.h>
  31 #include <stdio.h>
  32 #include <unistd.h>
  33 #include <string.h>
  34 #include <strings.h>
  35 #include <assert.h>
  36 
  37 #include <libmlrpc.h>

  38 
  39 
  40 /*
  41  * Global list of allocated handles.  Handles are used in various
  42  * server-side RPC functions: typically, issued when a service is
  43  * opened and obsoleted when it is closed.  Clients should treat
  44  * handles as opaque data.
  45  */
  46 static ndr_handle_t *ndr_handle_list;
  47 static mutex_t ndr_handle_lock;
  48 
  49 /*
  50  * Table of registered services.
  51  */
  52 #define NDR_MAX_SERVICES        32
  53 static ndr_service_t *ndr_services[NDR_MAX_SERVICES];
  54 
  55 /*
  56  * Register a service.
  57  *