diff options
author | Cyrill Gorcunov <gorcunov@gmail.com> | 2016-03-04 20:44:42 +0300 |
---|---|---|
committer | Cyrill Gorcunov <gorcunov@gmail.com> | 2016-03-04 20:44:42 +0300 |
commit | 92c02bb50df5a6489b618dd6a687ed8514762ecb (patch) | |
tree | bbe5bf13c4a2febc3b0f80436f59892de62250a2 | |
parent | a9a1b5c318e7bcb7680483c51933c6f3d6c69cd9 (diff) | |
download | nasm-92c02bb50df5a6489b618dd6a687ed8514762ecb.tar.gz |
listing: Don't try to open non-specified listing
By default we setup @listname to '\0' and if has
not been specified in command line it is passed
in this form into list_init() which cause
| [cyrill@uranus nasm.git] ./nasm -felf64 t.asm
| nasm: error: unable to open listing file `'
So make a proper test here.
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
-rw-r--r-- | listing.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -128,7 +128,7 @@ static void list_emit(void) static void list_init(const char *fname) { - if (!fname) { + if (!fname || fname[0] == '\0') { listfp = NULL; return; } |