util/glsl2spirv: fix type error in argument handling
authorDylan Baker <dylan.c.baker@intel.com>
Tue, 1 Nov 2022 19:40:21 +0000 (12:40 -0700)
committerMarge Bot <emma+marge@anholt.net>
Thu, 10 Nov 2022 21:14:17 +0000 (21:14 +0000)
args.Olib is set to `store_true`, which means it will always be `True`
or `False`, this means that the we always, unconditionally, add
`--keep-uncalled` to the command line.

fixes: 9786d9ef2abb45a4e832cf1347581e3ca3aae9f0

Reviewed-by: Luis Felipe Strano Moraes <luis.strano@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19449>

src/util/glsl2spirv.py

index f11bf612cb112b4b0050de8d372df6fab728248e..8b765c987eb52c56e6e5c5999d4d1541eb587f44 100644 (file)
@@ -129,7 +129,7 @@ def process_file(args):
 
         cmd_list = ["glslangValidator"]
 
-        if args.Olib is not None:
+        if args.Olib:
             cmd_list += ["--keep-uncalled"]
 
         if args.vn is not None: