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

fix: Make blisp check for existing file before flashing #69

Merged

Conversation

shymega
Copy link
Member

@shymega shymega commented Nov 16, 2024

This commit adds a simple check to both blisp commands that checks the
passed firmware .bin file exists, and is readable.

Justification: I flashed my Pinecil V2 that arrived today, and
misspelled the filename. blisp erased flash, and then exited - it did
not check the firmware .bin was readable/accessible, which meant my
Pinecil was soft-bricked.

I have tested the change, and it works for both commands when the input
file isn't readable.

I had to declare the cmd_{iot,write}_args_print_glossary function as
static before the call, so that we don't use undeclared functions before
we call them.

Signed-off-by: Dom Rodriguez [email protected]

@shymega shymega force-pushed the shymega-fix/check-bin-is-accessible branch 3 times, most recently from fe7d76a to d01d3de Compare November 16, 2024 22:22
This commit adds a simple check to both blisp commands that checks the
passed firmware .bin file exists, and is readable.

Justification: I flashed my Pinecil V2 that arrived today, and
misspelled the filename. blisp erased flash, and then exited - it did
not check the firmware .bin was readable/accessible, which meant my
Pinecil was soft-bricked.

I have tested the change, and it works for both commands when the input
file isn't readable.

I had to declare the `cmd_{iot,write}_args_print_glossary` function as
static before the call, so that we don't use undeclared functions before
we call them.

Signed-off-by: Dom Rodriguez <[email protected]>
@shymega shymega force-pushed the shymega-fix/check-bin-is-accessible branch from d01d3de to fb09967 Compare November 16, 2024 22:24
@gamelaster gamelaster merged commit d63612c into pine64:master Dec 1, 2024
6 checks passed
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