From: Björn Jacke Date: Sun, 25 Aug 2019 21:02:37 +0000 (+0200) Subject: samba_deps.py avoid inefficient string concatenations X-Git-Tag: talloc-2.3.1~743 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=432d9fd2214a4804a9cfefb9916e97efb9909c2c;p=thirdparty%2Fsamba.git samba_deps.py avoid inefficient string concatenations Signed-off-by: Bjoern Jacke Reviewed-by: Andrew Bartlett --- diff --git a/buildtools/wafsamba/samba_deps.py b/buildtools/wafsamba/samba_deps.py index 03c37079a8c..f400e1833a2 100644 --- a/buildtools/wafsamba/samba_deps.py +++ b/buildtools/wafsamba/samba_deps.py @@ -253,10 +253,8 @@ def add_init_functions(self): cflags.append('-DSTATIC_%s_MODULES_PROTO=%s' % (m, proto)) else: cflags.append('-DSTATIC_%s_MODULES=%s' % (m, ','.join(init_fn_list) + ',' + sentinel)) - proto='' - for f in init_fn_list: - proto += '_MODULE_PROTO(%s)' % f - proto += "extern void __%s_dummy_module_proto(void)" % (m) + proto = "".join('_MODULE_PROTO(%s)' % f for f in init_fn_list) +\ + "extern void __%s_dummy_module_proto(void)" % (m) cflags.append('-DSTATIC_%s_MODULES_PROTO=%s' % (m, proto)) self.cflags = cflags