Uploaded image for project: 'Guacamole'
  1. Guacamole
  2. GUACAMOLE-500

Terminal build fails against GCC 7

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 1.0.0
    • Terminal
    • None

    Description

      As reported in the mailing lists, when guacamole-server is built against GCC 7, an additional warning is flagged within typescript.c, resulting in the build failing:

      ...
      Making all in src/terminal
      make[2]: Entering directory '/home/mjumper/apache/guacamole/guacamole-server/src/terminal'
        CC       libguac_terminal_la-buffer.lo
        CC       libguac_terminal_la-char_mappings.lo
        CC       libguac_terminal_la-common.lo
        CC       libguac_terminal_la-display.lo
        CC       libguac_terminal_la-named-colors.lo
        CC       libguac_terminal_la-palette.lo
        CC       libguac_terminal_la-scrollbar.lo
        CC       libguac_terminal_la-terminal.lo
        CC       libguac_terminal_la-terminal_handlers.lo
        CC       libguac_terminal_la-typescript.lo
      typescript.c: In function ‘guac_terminal_typescript_alloc’:
      typescript.c:133:46: error: ‘%s’ directive writing 6 bytes into a region of size between 0 and 2047 [-Werror=format-overflow=]
           sprintf(typescript->timing_filename, "%s.%s", typescript->data_filename,
                                                    ^~
      typescript.c:133:5: note: ‘sprintf’ output between 8 and 2055 bytes into a destination of size 2048
           sprintf(typescript->timing_filename, "%s.%s", typescript->data_filename,
           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                   GUAC_TERMINAL_TYPESCRIPT_TIMING_SUFFIX);
                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      cc1: all warnings being treated as errors
      make[2]: *** [Makefile:572: libguac_terminal_la-typescript.lo] Error 1
      make[2]: Leaving directory '/home/mjumper/apache/guacamole/guacamole-server/src/terminal'
      make[1]: *** [Makefile:517: all-recursive] Error 1
      make[1]: Leaving directory '/home/mjumper/apache/guacamole/guacamole-server'
      make: *** [Makefile:439: all] Error 2
      

      Attachments

        Activity

          People

            mjumper Mike Jumper
            mjumper Mike Jumper
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: