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

Diff for /src/usr.bin/aucat/Attic/wav.c between version 1.2 and 1.3

version 1.2, 2008/11/26 00:33:40 version 1.3, 2009/01/23 17:38:15
Line 12 
Line 12 
  * max data of a .wav file. The total file size must be smaller than   * max data of a .wav file. The total file size must be smaller than
  * 2^31, and we also have to leave some space for the headers (around 40   * 2^31, and we also have to leave some space for the headers (around 40
  * bytes)   * bytes)
  */   */
 #define WAV_DATAMAX     (0x7fff0000)  #define WAV_DATAMAX     (0x7fff0000)
   
 struct fileops wav_ops = {  struct fileops wav_ops = {
Line 54 
Line 54 
         f = (struct wav *)pipe_new(ops, fd, name);          f = (struct wav *)pipe_new(ops, fd, name);
         if (hdr == HDR_WAV) {          if (hdr == HDR_WAV) {
                 par->le = 1;                  par->le = 1;
                 par->sig = (par->bits <= 8) ? 0 : 1;                  par->sig = (par->bits <= 8) ? 0 : 1;
                 par->bps = (par->bits + 7) / 8;                  par->bps = (par->bits + 7) / 8;
                 if (!wav_writehdr(f->pipe.fd, par))                  if (!wav_writehdr(f->pipe.fd, par))
                         exit(1);                          exit(1);
Line 92 
Line 92 
 {  {
         struct wav *f = (struct wav *)file;          struct wav *f = (struct wav *)file;
         unsigned n;          unsigned n;
   
         if (f->wbytes >= 0 && count > f->wbytes) {          if (f->wbytes >= 0 && count > f->wbytes) {
                 count = f->wbytes; /* wbytes fits in count */                  count = f->wbytes; /* wbytes fits in count */
                 if (count == 0) {                  if (count == 0) {

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