From b19ba2254851018760cf56680f7bcdb303242fbc Mon Sep 17 00:00:00 2001 From: Joe Guo Date: Mon, 7 May 2018 10:18:42 +1200 Subject: [PATCH] traffic_replay: fetch domain from creds other than opts For traffic_replay script, when user provides `--workgroup` or `-W` option from command line, it will be set on the creds option group, other than the opts one. So while checking this option, we should check it against creds. The previous code is actually loading domain from lp, which get data from the smb.conf file. Signed-off-by: Joe Guo --- script/traffic_replay | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/traffic_replay b/script/traffic_replay index 0e97d0a64af..bf2d2448034 100755 --- a/script/traffic_replay +++ b/script/traffic_replay @@ -156,7 +156,7 @@ def main(): lp = sambaopts.get_loadparm() creds = credopts.get_credentials(lp) - domain = opts.workgroup + domain = creds.get_domain() if domain: lp.set("workgroup", domain) else: