mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
r1786: Add support for the 'helpstring' attribute on interfaces
This commit is contained in:
parent
44083e3178
commit
85fb26a05d
@ -278,7 +278,12 @@ sub HeaderInterface($)
|
|||||||
|
|
||||||
if(!defined $interface->{PROPERTIES}->{version}) { $interface->{PROPERTIES}->{version} = "0.0"; }
|
if(!defined $interface->{PROPERTIES}->{version}) { $interface->{PROPERTIES}->{version} = "0.0"; }
|
||||||
$res .= "#define DCERPC_$name\_VERSION $interface->{PROPERTIES}->{version}\n";
|
$res .= "#define DCERPC_$name\_VERSION $interface->{PROPERTIES}->{version}\n";
|
||||||
|
|
||||||
$res .= "#define DCERPC_$name\_NAME \"$interface->{NAME}\"\n\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 .= "extern const struct dcerpc_interface_table dcerpc_table_$interface->{NAME};\n";
|
||||||
$res .= "NTSTATUS dcerpc_$interface->{NAME}_init(void);\n\n";
|
$res .= "NTSTATUS dcerpc_$interface->{NAME}_init(void);\n\n";
|
||||||
}
|
}
|
||||||
|
@ -1383,6 +1383,7 @@ sub FunctionTable($)
|
|||||||
pidl "\t\"$interface->{NAME}\",\n";
|
pidl "\t\"$interface->{NAME}\",\n";
|
||||||
pidl "\tDCERPC_$uname\_UUID,\n";
|
pidl "\tDCERPC_$uname\_UUID,\n";
|
||||||
pidl "\tDCERPC_$uname\_VERSION,\n";
|
pidl "\tDCERPC_$uname\_VERSION,\n";
|
||||||
|
pidl "\tDCERPC_$uname\_HELPSTRING,\n";
|
||||||
pidl "\t$count,\n";
|
pidl "\t$count,\n";
|
||||||
pidl "\t$interface->{NAME}\_calls,\n";
|
pidl "\t$interface->{NAME}\_calls,\n";
|
||||||
pidl "\t&$interface->{NAME}\_endpoints\n";
|
pidl "\t&$interface->{NAME}\_endpoints\n";
|
||||||
|
@ -105,6 +105,7 @@ struct dcerpc_interface_table {
|
|||||||
const char *name;
|
const char *name;
|
||||||
const char *uuid;
|
const char *uuid;
|
||||||
uint32_t if_version;
|
uint32_t if_version;
|
||||||
|
const char *helpstring;
|
||||||
uint32_t num_calls;
|
uint32_t num_calls;
|
||||||
const struct dcerpc_interface_call *calls;
|
const struct dcerpc_interface_call *calls;
|
||||||
const struct dcerpc_endpoint_list *endpoints;
|
const struct dcerpc_endpoint_list *endpoints;
|
||||||
|
@ -69,7 +69,11 @@ static void show_pipes(void)
|
|||||||
printf("\nYou must specify a pipe\n");
|
printf("\nYou must specify a pipe\n");
|
||||||
printf("known pipes are:\n");
|
printf("known pipes are:\n");
|
||||||
for (i=0;dcerpc_pipes[i];i++) {
|
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);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user