Skip to content

Fails to build on Arch #2

@vlovich

Description

@vlovich

The declaration of ais_charset.c generates a warning on GCC 15 which fails if you build with Werror=format-security (the default on Arch).

ais_charset.c:3:24: error: initializer-string for array of ‘char’ truncates NUL terminator but destination lacks ‘nonstring’ attribute (65 chars into 64 available) [-Werror=unterminated-string-initialization]
    3 | char ais_charset[64] = "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_ !\"#$%&'()*+,-./0123456789:;<=>?";
      |                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  SoapySDR support: yes

This should either be ais_charset[65] or ais_charset[64] __attribute__((nonstring)) (not sure about the target compilers to be supported in the code - the attribute may need to be hidden behind a macro).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions