q3map2: fix segfault when missing bspfile arg on light stage
Bug seen while investigating #138 (closed).
Before:
$ q3map2 -light
2.5.17n-git-f41ca5cd
threads: 8
Q3Map - v1.0r (c) 1999 Id Software Inc.
Q3Map (ydnar) - v2.5.17n-git-f41ca5cd
NetRadiant - v1.5.0 Jan 30 2020 20:27:00
Your map saw the pretty lights from q3map2's BFG
VFS Init: /home/illwieckz/.q3a/baseq3/
VFS Init: /home/illwieckz/dev/netradiant/install/baseq3/
--- Light ---
--- ProcessGameSpecific ---
lightning model: quake3
lightmap size: 128 x 128 pixels
lightning gamma: 1.000000
lightmap colorspace: linear
texture colorspace: linear
_color colorspace: linear
lightning compensation: 1.000000
lightning exposure: 0.000000
lightgrid scale: 1.000000
lightgrid ambient scale: 1.000000
shader lightstyles hack: enabled
patch shadows: disabled
deluxemapping: disabled
--- ProcessCommandLine ---
Erreur de segmentation
After:
$ q3map2 -light
2.5.17n-git-d0ddc5a3
threads: 8
Q3Map - v1.0r (c) 1999 Id Software Inc.
Q3Map (ydnar) - v2.5.17n-git-f41ca5cd
NetRadiant - v1.5.0 Mar 27 2020 01:39:21
Your map saw the pretty lights from q3map2's BFG
VFS Init: /home/illwieckz/.q3a/baseq3/
VFS Init: /home/illwieckz/dev/netradiant/install/baseq3/
--- Light ---
--- ProcessGameSpecific ---
lightning model: quake3
lightmap size: 128 x 128 pixels
lightning gamma: 1.000000
lightmap colorspace: linear
texture colorspace: linear
_color colorspace: linear
lightning compensation: 1.000000
lightning exposure: 0.000000
lightgrid scale: 1.000000
lightgrid ambient scale: 1.000000
shader lightstyles hack: enabled
patch shadows: disabled
deluxemapping: disabled
--- ProcessCommandLine ---
************ ERROR ************
usage: q3map -light [options] bspfile