Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

string/strspn/strrcspn.h: assignment discards 'const' qualifier from pointer target type #1218

Open
zeha opened this issue Feb 19, 2025 · 1 comment · May be fixed by #1220
Open

string/strspn/strrcspn.h: assignment discards 'const' qualifier from pointer target type #1218

zeha opened this issue Feb 19, 2025 · 1 comment · May be fixed by #1220

Comments

@zeha
Copy link
Contributor

zeha commented Feb 19, 2025

libtool: compile:  gcc -I. -I.. -I.. -isystem /usr/include/aarch64-linux-gnu/bsd -DLIBBSD_OVERLAY -lsystemd -O2 -Wall -Wextra -Werror=implicit-function-declaration -Werror=implicit-int -Werror=incompatible-pointer-types -Werror=int-conversion -Wno-expansi
on-to-defined -Wno-unknown-attributes -Wno-unknown-warning-option -MT libshadow_la-getdef.lo -MD -MP -MF .deps/libshadow_la-getdef.Tpo -c getdef.c  -fPIC -DPIC -o .libs/libshadow_la-getdef.o
In file included from string/strspn/stprspn.h:13,
                 from getdef.c:36:
./string/strspn/strrspn.h: In function 'strrspn_':
./string/strspn/strrspn.h:29:11: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
   29 |         p = strnul(s);
      |           ^

seen on current master 77eb67d

/cc @alejandro-colomar

@alejandro-colomar
Copy link
Collaborator

I'll fix that in a moment. Thanks for the report!

Let's see if we can get rid of all const-related existing diagnostics and then promote it to an error.

alejandro-colomar added a commit to alejandro-colomar/shadow that referenced this issue Feb 19, 2025
Closes: <shadow-maint#1218>
Reported-by: Chris Hofstaedtler <zeha@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
@alejandro-colomar alejandro-colomar linked a pull request Feb 19, 2025 that will close this issue
alejandro-colomar added a commit to alejandro-colomar/shadow that referenced this issue Feb 19, 2025
Closes: <shadow-maint#1218>
Reported-by: Chris Hofstaedtler <zeha@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
alejandro-colomar added a commit to alejandro-colomar/shadow that referenced this issue Mar 3, 2025
Closes: <shadow-maint#1218>
Reported-by: Chris Hofstaedtler <zeha@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
alejandro-colomar added a commit to alejandro-colomar/shadow that referenced this issue Mar 4, 2025
Closes: <shadow-maint#1218>
Reported-by: Chris Hofstaedtler <zeha@debian.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants