[asterisk-bugs] [JIRA] (PRI-186) libpri fails to build with GCC 10

Tzafrir Cohen (JIRA) noreply at issues.asterisk.org
Wed Aug 19 16:15:43 CDT 2020


Tzafrir Cohen created PRI-186:
---------------------------------

             Summary: libpri fails to build with GCC 10
                 Key: PRI-186
                 URL: https://issues.asterisk.org/jira/browse/PRI-186
             Project: LibPRI
          Issue Type: Bug
      Security Level: None
          Components: General
    Affects Versions: 1.6.0
         Environment: Debian Testing (11)
            Reporter: Tzafrir Cohen
            Assignee: Richard Mudgett


{code}
q931.c: In function ‘q931_receive’:
q931.c:7688:25: error: array subscript 17 is outside the bounds of an interior zero-length array ‘unsigned char[0]’ [-Werror=zero-length-bounds]
 7688 |    h->raw[h->crlen + 2] -= 0x8;
      |                         ^~
In file included from pri_internal.h:36,
                 from q931.c:32:
pri_q931.h:40:16: note: while referencing ‘raw’
   40 |  unsigned char raw[0];
      |                ^~~
q931.c:7688:25: error: array subscript 17 is outside the bounds of an interior zero-length array ‘unsigned char[0]’ [-Werror=zero-length-bounds]
 7688 |    h->raw[h->crlen + 2] -= 0x8;
      |    ~~~~~~~~~~~~~~~~~~~~~^~~~~~
In file included from pri_internal.h:36,
                 from q931.c:32:
pri_q931.h:40:16: note: while referencing ‘raw’
   40 |  unsigned char raw[0];
      |                ^~~
{code}

See Debian issue https://bugs.debian.org/957470



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list