]> git.tuebingen.mpg.de Git - paraslash.git/blobdiff - vss.c
afs.cmd: Update help output.
[paraslash.git] / vss.c
diff --git a/vss.c b/vss.c
index 98ad11f610087ffd5319adbbb8ecf503ccdb3b88..e6cf59676fe4699b85501b5334de8c99b090a4f1 100644 (file)
--- a/vss.c
+++ b/vss.c
  * senders.
  */
 
+#include <sys/mman.h> /* mmap */
+#include <sys/time.h> /* gettimeofday */
+#include <sys/types.h>
+#include <dirent.h>
+
 #include "para.h"
 #include "afh.h"
 #include "server.h"
-#include <sys/mman.h> /* mmap */
-#include <sys/time.h> /* gettimeofday */
 #include "server.cmdline.h"
 #include "afs_common.h"
 #include "vss.h"
@@ -153,8 +156,9 @@ unsigned int vss_paused(void)
  */
 const char *audio_format_name(int i)
 {
-       assert(i >= 0 && i < ARRAY_SIZE(afl));
-       return afl[i].name;
+       //PARA_NOTICE_LOG("array size: %u¸ requested: %d\n", ARRAY_SIZE(afl), i);
+       assert(i < 0 || i < ARRAY_SIZE(afl) - 1);
+       return i >= 0?  afl[i].name : "(none)";
 }
 
 /**