-
Notifications
You must be signed in to change notification settings - Fork 136
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
Automatic verification is designed to fail for stdin #1044
Comments
The following should give a verification error
|
Thanks for reporting! Would be great if a solution to this would be something #1036 could benefit from.
Ooh, this could be very useful! |
Indeed this is an issue. Verfication after writing will fail even though the writing itself is good.
|
I'm not a big fan of global variables … but we certainly ought to do something, I agree. |
The simplest fix is probably documentation fix to mention this limitation of the current implementation -- and then provide the workaround of using |
Fixed by PR #1053 |
Problem. Currently, automatic verification is instigated during option parsing of
-U
throughavrdude/src/main.c
Lines 528 to 532 in affe4cb
So, each
-U memory:w:file:...
will see a verification request-U memory:v:file:...
inserted into the update action list after the write request (unless-V
was specified before the-U
). This is designed to fail if file is stdin-
as the file is read twice.Proposed solution. I would make
verify
a global variable, remove above lines and change the code for writing to memory that it checks against the already read file (so that does not need to be read twice).(Making
verify
global also helps the micronucleus programmer print a warning that it needs to switch offverify
because the micronucleus bootloader cannot read flash.)The text was updated successfully, but these errors were encountered: