-
Notifications
You must be signed in to change notification settings - Fork 8
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
Use After Free error #55
Comments
Here’s what I get with the new
So it’s cloning hiredis, which is good. Looks like I’m still needing to uncomment |
Here’s a Dockerfile that will reproduce the test case:
Save that to a file named Uncomment the |
Looking at the offending code, it seems like the compiler is just pitching a fit.
My guess is (I haven’t done any serious C coding since the nineties) if you simply used a different variable to hold the results of |
Hmm. Changing the assignment to a new variable didn’t help; the compiler is convinced that one of the preceding (inlined) functions is calling I’m at a loss. |
I reproduced the warnning. It doesn't look like a real problem. |
That works for me! |
Hi guys. I ran into this right now when building sonic-net/sonic-buildimage with debian:bookworm, which uses: The Build default:
Building with altered flags:
Without the
And with
Awkward. Both those cases are falsely flagged by the compiler. (When |
Hi @moticless, what's your opinion? Hope this issue can be fixed ASAP. Thanks. |
…ree) (#20759) Fix #20757 Why I did it To Fix the issue: redis-cli build broken on Debian/Bookworm (librdb use-after-free) #20757 How I did it This issue is a known open issue below: redis/librdb#55 According to Walter Doekes's solution, currently to work around it by adding -floto=auto compiler option. make -j$(SONIC_CONFIG_MAKE_JOBS) WARNS='-Wall -Wextra -pedantic -flto=auto'
Hi @JunhongMao , |
Yes. My pleasure.
|
…ree) (sonic-net#20759) Fix sonic-net#20757 Why I did it To Fix the issue: redis-cli build broken on Debian/Bookworm (librdb use-after-free) sonic-net#20757 How I did it This issue is a known open issue below: redis/librdb#55 According to Walter Doekes's solution, currently to work around it by adding -floto=auto compiler option. make -j$(SONIC_CONFIG_MAKE_JOBS) WARNS='-Wall -Wextra -pedantic -flto=auto'
…ree) (#20759) Fix #20757 Why I did it To Fix the issue: redis-cli build broken on Debian/Bookworm (librdb use-after-free) #20757 How I did it This issue is a known open issue below: redis/librdb#55 According to Walter Doekes's solution, currently to work around it by adding -floto=auto compiler option. make -j$(SONIC_CONFIG_MAKE_JOBS) WARNS='-Wall -Wextra -pedantic -flto=auto'
…ree) (sonic-net#20759) Fix sonic-net#20757 Why I did it To Fix the issue: redis-cli build broken on Debian/Bookworm (librdb use-after-free) sonic-net#20757 How I did it This issue is a known open issue below: redis/librdb#55 According to Walter Doekes's solution, currently to work around it by adding -floto=auto compiler option. make -j$(SONIC_CONFIG_MAKE_JOBS) WARNS='-Wall -Wextra -pedantic -flto=auto'
Thanks for this project; I was able to migrate off of Redis 7.4 after I inadvertently upgraded my databases.
To get it to build under Debian I had to comment out
-Werror
fromdeps/redis/Makefile
as it was complaining about a potentialuse-after-free
error. With that commented out it built and ran fine (once I figured out I needed to clonehiredis
; might want to add that to the documentation).The text was updated successfully, but these errors were encountered: