smbdotconf: mark "enumports command" with substitution="1"
authorRalph Boehme <slow@samba.org>
Mon, 4 Nov 2019 16:42:38 +0000 (17:42 +0100)
committerStefan Metzmacher <metze@samba.org>
Wed, 27 Nov 2019 10:25:34 +0000 (10:25 +0000)
Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
docs-xml/smbdotconf/printing/enumportscommand.xml
source3/rpc_server/spoolss/srv_spoolss_nt.c

index cb85cd0bcc80819fc6ea45fb2de1e0f7d95695a2..12580420d722576730e287cbcc71396385d5646c 100644 (file)
@@ -1,6 +1,7 @@
 <samba:parameter name="enumports command"
                  context="G"
                  type="string"
+                 substitution="1"
                  xmlns:samba="http://www.samba.org/samba/DTD/samba-doc">
 <description>
     <para>The concept of a &quot;port&quot; is fairly foreign
index 631091a5ce04312d28160b71c1d6111bcec91df7..33eaca5dea54e98a1251ad7d627bbdc11165cb3f 100644 (file)
@@ -8190,7 +8190,9 @@ static WERROR fill_port_2(TALLOC_CTX *mem_ctx,
 
 static WERROR enumports_hook(TALLOC_CTX *ctx, int *count, char ***lines)
 {
-       char *cmd = lp_enumports_command(talloc_tos());
+       const struct loadparm_substitution *lp_sub =
+               loadparm_s3_global_substitution();
+       char *cmd = lp_enumports_command(talloc_tos(), lp_sub);
        char **qlines = NULL;
        char *command = NULL;
        int numlines;