Skip to content

errors in builing #24

Description

@honors1

Dear Dongdong She,

I got the errors in building as follows. How to handle this error?

$ gcc -O3 -funroll-loops ./neuzz.c -o neuzz
./neuzz.c: In function ‘copy_seeds’:
./neuzz.c:1820:26: warning: ‘%s’ directive writing up to 255 bytes into a region of size 127 [-Wformat-overflow=]
1820 | sprintf(src, "%s/%s", in_dir, de->d_name);
| ^~
In file included from /usr/include/stdio.h:867,
from ./neuzz.c:3:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: ‘__builtin___sprintf_chk’ output 2 or more bytes (assuming 257) into a destination of size 128
36 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
37 | __bos (__s), __fmt, __va_arg_pack ());
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./neuzz.c:1821:26: warning: ‘%s’ directive writing up to 255 bytes into a region of size 127 [-Wformat-overflow=]
1821 | sprintf(dst, "%s/%s", out_dir, de->d_name);
| ^~
In file included from /usr/include/stdio.h:867,
from ./neuzz.c:3:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: ‘__builtin___sprintf_chk’ output 2 or more bytes (assuming 257) into a destination of size 128
36 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
37 | __bos (__s), __fmt, __va_arg_pack ());
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


My environment is as following:

  • OS: Ubuntu 20.04
  • Python: conda virtual environment python=2.7 on miniconda 3.7
  • gcc: gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions