[GH-ISSUE #2801] String overflow warning with gcc 9.1 on Arch Linux #1755

Closed
opened 2026-05-05 08:25:32 -06:00 by gitea-mirror · 0 comments
Owner

Originally created by @Vincent43 on GitHub (Jun 27, 2019).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2801

In file included from /usr/include/string.h:494,
                 from ../include/common.h:31,
                 from firejail.h:22,
                 from x11.c:20:
In function ‘strncat’,
    inlined from ‘x11_start_xpra_new’ at x11.c:896:3:
/usr/include/bits/string_fortified.h:136:10: warning: ‘__builtin_strncat’ specified bound depends on the length of the source argument [-Wstringop-overflow=]
  136 |   return __builtin___strncat_chk (__dest, __src, __len, __bos (__dest));
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
x11.c: In function ‘x11_start_xpra_new’:
x11.c:896:3: note: length computed here
  896 |   strncat(start_child,firejail_argv[i],strlen(firejail_argv[i]));
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Originally created by @Vincent43 on GitHub (Jun 27, 2019). Original GitHub issue: https://github.com/netblue30/firejail/issues/2801 ``` In file included from /usr/include/string.h:494, from ../include/common.h:31, from firejail.h:22, from x11.c:20: In function ‘strncat’, inlined from ‘x11_start_xpra_new’ at x11.c:896:3: /usr/include/bits/string_fortified.h:136:10: warning: ‘__builtin_strncat’ specified bound depends on the length of the source argument [-Wstringop-overflow=] 136 | return __builtin___strncat_chk (__dest, __src, __len, __bos (__dest)); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ x11.c: In function ‘x11_start_xpra_new’: x11.c:896:3: note: length computed here 896 | strncat(start_child,firejail_argv[i],strlen(firejail_argv[i])); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ```
gitea-mirror 2026-05-05 08:25:32 -06:00
  • closed this issue
  • added the
    bug
    label
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#1755
No description provided.