[BACK]Return to opt.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / aucat

Diff for /src/usr.bin/aucat/Attic/opt.c between version 1.3 and 1.4

version 1.3, 2009/11/03 21:31:37 version 1.4, 2010/01/10 21:47:41
Line 20 
Line 20 
   
 #include "conf.h"  #include "conf.h"
 #include "opt.h"  #include "opt.h"
   #ifdef DEBUG
   #include "dbg.h"
   #endif
   
 struct optlist opt_list = SLIST_HEAD_INITIALIZER(&opt_list);  struct optlist opt_list = SLIST_HEAD_INITIALIZER(&opt_list);
   
Line 55 
Line 58 
         o->rpar = *rpar;          o->rpar = *rpar;
         o->maxweight = maxweight;          o->maxweight = maxweight;
         o->mmc = mmc;          o->mmc = mmc;
   #ifdef DEBUG
           if (debug_level >= 2) {
                   dbg_puts(o->name);
                   dbg_puts(": rec ");
                   aparams_dbg(&o->wpar);
                   dbg_puts(", play ");
                   aparams_dbg(&o->rpar);
                   dbg_puts(", vol ");
                   dbg_putu(o->maxweight);
                   if (o->mmc)
                           dbg_puts(", mmc");
                   dbg_puts("\n");
           }
   #endif
         SLIST_INSERT_HEAD(&opt_list, o, entry);          SLIST_INSERT_HEAD(&opt_list, o, entry);
 }  }
   
Line 65 
Line 82 
   
         SLIST_FOREACH(o, &opt_list, entry) {          SLIST_FOREACH(o, &opt_list, entry) {
                 if (strcmp(name, o->name) == 0) {                  if (strcmp(name, o->name) == 0) {
   #ifdef DEBUG
                           if (debug_level >= 3) {
                                   dbg_puts(o->name);
                                   dbg_puts(": option found\n");
                           }
   #endif
                         return o;                          return o;
                 }                  }
         }          }
   #ifdef DEBUG
           if (debug_level >= 3) {
                   dbg_puts(name);
                   dbg_puts(": option not found\n");
           }
   #endif
         return NULL;          return NULL;
 }  }
   

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4