OSDN Git Service

Fix to avoid segmentation fault when "." or nonexistent archive name is given
authorShoichi Tamuki <tamuki@linet.gr.jp>
Fri, 5 Jan 2007 06:40:11 +0000 (06:40 +0000)
committerShoichi Tamuki <tamuki@linet.gr.jp>
Fri, 5 Jan 2007 06:40:11 +0000 (06:40 +0000)
ChangeLog
timidity/timidity.c

index 752f98b..47360ca 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,11 @@
-2007-1-4  Keishi Suenaga <skeishi@yahoo.co.jp>
+2007-01-05  TAMUKI Shoichi <tamuki@linet.gr.jp>
 
-    Fix -iW and timiditydrv.dll sound problem.
+       * timidity/timidity.c (main): Fix to avoid segmentation fault
+         when "." or nonexistent archive name is given
+
+2007-01-04  Keishi Suenaga <skeishi@yahoo.co.jp>
+
+       Fix -iW and timiditydrv.dll sound problem.
        * timidity/portaudio_a.c: fix buffer overlow.
 
 2007-01-04  TAMUKI Shoichi <tamuki@linet.gr.jp>
index 6277d3f..d39404f 100644 (file)
@@ -5806,7 +5806,8 @@ int main(int argc, char **argv)
                        && ctl->id_character != 'r' && ctl->id_character != 'A'
                        && ctl->id_character != 'W' && ctl->id_character != 'P')
                files = expand_file_archives(files, &nfiles);
-       files_nbuf = files[0];
+       if (nfiles > 0)
+               files_nbuf = files[0];
 #if !defined(IA_W32GUI) && !defined(IA_W32G_SYN)
        if (dumb_error_count)
                sleep(1);