svn commit: samba r1786 - in branches/SAMBA_4_0/source: build/pidl
librpc/rpc utils
jelmer at samba.org
jelmer at samba.org
Thu Aug 12 19:32:16 GMT 2004
Author: jelmer
Date: 2004-08-12 19:32:16 +0000 (Thu, 12 Aug 2004)
New Revision: 1786
WebSVN: http://websvn.samba.org/websvn/changeset.php?rep=samba&path=/branches/SAMBA_4_0/source&rev=1786&nolog=1
Log:
Add support for the 'helpstring' attribute on interfaces
Modified:
branches/SAMBA_4_0/source/build/pidl/header.pm
branches/SAMBA_4_0/source/build/pidl/parser.pm
branches/SAMBA_4_0/source/librpc/rpc/dcerpc.h
branches/SAMBA_4_0/source/utils/ndrdump.c
Changeset:
Modified: branches/SAMBA_4_0/source/build/pidl/header.pm
===================================================================
--- branches/SAMBA_4_0/source/build/pidl/header.pm 2004-08-12 19:29:52 UTC (rev 1785)
+++ branches/SAMBA_4_0/source/build/pidl/header.pm 2004-08-12 19:32:16 UTC (rev 1786)
@@ -278,7 +278,12 @@
if(!defined $interface->{PROPERTIES}->{version}) { $interface->{PROPERTIES}->{version} = "0.0"; }
$res .= "#define DCERPC_$name\_VERSION $interface->{PROPERTIES}->{version}\n";
+
$res .= "#define DCERPC_$name\_NAME \"$interface->{NAME}\"\n\n";
+
+ if(!defined $interface->{PROPERTIES}->{helpstring}) { $interface->{PROPERTIES}->{helpstring} = "NULL"; }
+ $res .= "#define DCERPC_$name\_HELPSTRING $interface->{PROPERTIES}->{helpstring}\n";
+
$res .= "extern const struct dcerpc_interface_table dcerpc_table_$interface->{NAME};\n";
$res .= "NTSTATUS dcerpc_$interface->{NAME}_init(void);\n\n";
}
Modified: branches/SAMBA_4_0/source/build/pidl/parser.pm
===================================================================
--- branches/SAMBA_4_0/source/build/pidl/parser.pm 2004-08-12 19:29:52 UTC (rev 1785)
+++ branches/SAMBA_4_0/source/build/pidl/parser.pm 2004-08-12 19:32:16 UTC (rev 1786)
@@ -1383,6 +1383,7 @@
pidl "\t\"$interface->{NAME}\",\n";
pidl "\tDCERPC_$uname\_UUID,\n";
pidl "\tDCERPC_$uname\_VERSION,\n";
+ pidl "\tDCERPC_$uname\_HELPSTRING,\n";
pidl "\t$count,\n";
pidl "\t$interface->{NAME}\_calls,\n";
pidl "\t&$interface->{NAME}\_endpoints\n";
Modified: branches/SAMBA_4_0/source/librpc/rpc/dcerpc.h
===================================================================
--- branches/SAMBA_4_0/source/librpc/rpc/dcerpc.h 2004-08-12 19:29:52 UTC (rev 1785)
+++ branches/SAMBA_4_0/source/librpc/rpc/dcerpc.h 2004-08-12 19:32:16 UTC (rev 1786)
@@ -105,6 +105,7 @@
const char *name;
const char *uuid;
uint32_t if_version;
+ const char *helpstring;
uint32_t num_calls;
const struct dcerpc_interface_call *calls;
const struct dcerpc_endpoint_list *endpoints;
Modified: branches/SAMBA_4_0/source/utils/ndrdump.c
===================================================================
--- branches/SAMBA_4_0/source/utils/ndrdump.c 2004-08-12 19:29:52 UTC (rev 1785)
+++ branches/SAMBA_4_0/source/utils/ndrdump.c 2004-08-12 19:32:16 UTC (rev 1786)
@@ -69,7 +69,11 @@
printf("\nYou must specify a pipe\n");
printf("known pipes are:\n");
for (i=0;dcerpc_pipes[i];i++) {
- printf("\t%s\n", dcerpc_pipes[i]->name);
+ if(dcerpc_pipes[i]->helpstring) {
+ printf("\t%s - %s\n", dcerpc_pipes[i]->name, dcerpc_pipes[i]->helpstring);
+ } else {
+ printf("\t%s\n", dcerpc_pipes[i]->name);
+ }
}
exit(1);
}
More information about the samba-cvs
mailing list