Print this page
10101 audio tools need smatch fixes

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/audio/audioplay/audioplay.c
          +++ new/usr/src/cmd/audio/audioplay/audioplay.c
↓ open down ↓ 15 lines elided ↑ open up ↑
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
  22   22   * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23   23   * Use is subject to license terms.
  24   24   */
  25   25  
       26 +/*
       27 + * Copyright (c) 2018, Joyent, Inc.
       28 + */
       29 +
  26   30  /* Command-line audio play utility */
  27   31  
  28   32  #include <stdio.h>
  29   33  #include <errno.h>
  30   34  #include <ctype.h>
  31   35  #include <string.h>
  32   36  #include <stdlib.h>
  33   37  #include <fcntl.h>
  34   38  #include <signal.h>
  35   39  #include <locale.h>
↓ open down ↓ 759 lines elided ↑ open up ↑
 795  799                  default:
 796  800                          break;
 797  801                  }
 798  802  
 799  803  closeinput:;
 800  804                  if (mapaddr != 0)
 801  805                          (void) munmap(mapaddr, st.st_size);
 802  806                  (void) close(ifd);              /* close input file */
 803  807                  if (Errdetect) {
 804  808                          cnt = 0;
 805      -                        audio_set_play_error(Audio_fd, (unsigned int *)&cnt);
      809 +                        (void) audio_set_play_error(Audio_fd,
      810 +                            (unsigned int *)&cnt);
 806  811                          if (cnt) {
 807  812                                  Error(stderr,
 808  813                                      MGET("%s: output underflow in %s\n"),
 809  814                                      Ifile, prog);
 810  815                                  errorStatus++;
 811  816                          }
 812  817                  }
 813  818  nextfile:;
 814  819          } while ((argc > 0) && (argc--, (Ifile = *argv++) != NULL));
 815  820  
↓ open down ↓ 336 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX