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

fuzz: fix build error #3861

Merged
merged 1 commit into from
May 15, 2023
Merged

Conversation

manunio
Copy link
Contributor

@manunio manunio commented May 15, 2023

Description

wasmer's oss-fuzz build was failing with following error:

error: variable does not need to be mutable
   --> lib/compiler-llvm/src/compiler.rs:279:25
    |
279 |                     for mut reloc in &mut custom_section.relocations {
    |                         ----^^^^^
    |                         |
    |                         help: remove this `mut`
    |
note: the lint level is defined here
   --> lib/compiler-llvm/src/lib.rs:4:5
    |
4   |     unused_mut,
    |     ^^^^^^^^^^

error: variable does not need to be mutable
   --> lib/compiler-llvm/src/compiler.rs:291:29
    |
291 |                         for mut reloc in &mut custom_section.relocations {
    |                             ----^^^^^
    |                             |
    |                             help: remove this `mut`

error: variable does not need to be mutable
   --> lib/compiler-llvm/src/compiler.rs:306:21
    |
306 |                 for mut reloc in &mut compiled_function.compiled_function.relocations {
    |                     ----^^^^^
    |                     |
    |                     help: remove this `mut`

error: could not compile `wasmer-compiler-llvm` (lib) due to 3 previous errors

This pr attempts to fix that by removing unused mut.
Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=58561

@manunio manunio marked this pull request as ready for review May 15, 2023 10:00
@ptitSeb
Copy link
Contributor

ptitSeb commented May 15, 2023

Thanks for the fix!

@ptitSeb ptitSeb merged commit edc9740 into wasmerio:master May 15, 2023
@manunio manunio deleted the oss-fuzz-fix-build-error branch May 15, 2023 12:26
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 this pull request may close these issues.

2 participants