fixed the rpc epmapper server. This fixes rpc over tcp.
authorAndrew Tridgell <tridge@samba.org>
Fri, 9 Jan 2004 02:43:23 +0000 (02:43 +0000)
committerAndrew Tridgell <tridge@samba.org>
Fri, 9 Jan 2004 02:43:23 +0000 (02:43 +0000)
(This used to be commit 6ac547fa5fe4b1926bafc46e500b51486c7d500d)

source4/rpc_server/epmapper/rpc_epmapper.c

index f3285729a69a6488233c7e9371310c49ab63af7c..7bfeaf2feea41fee2be404cf73644b327b091087 100644 (file)
@@ -116,11 +116,28 @@ static uint32 build_ep_list(TALLOC_CTX *mem_ctx,
                            struct dcesrv_endpoint *endpoint_list,
                            struct dcesrv_ep_iface **eps)
 {
+       struct dcesrv_endpoint *d;
        uint32 total = 0;
 
        (*eps) = NULL;
        
-       /* TODO */
+       for (d=endpoint_list; d; d=d->next) {
+               struct dcesrv_if_list *iface;
+
+               for (iface=d->interface_list;iface;iface=iface->next) {
+                       (*eps) = talloc_realloc_p(mem_ctx, *eps, 
+                                                 struct dcesrv_ep_iface,
+                                                 total + 1);
+                       if (!*eps) {
+                               return 0;
+                       }
+                       (*eps)[total].name = iface->iface.ndr->name;
+                       (*eps)[total].uuid = iface->iface.ndr->uuid;
+                       (*eps)[total].if_version = iface->iface.ndr->if_version;
+                       (*eps)[total].ep_description = d->ep_description;
+                       total++;
+               }
+       }
 
        return total;
 }