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

Doesn't write the end of the input file in some cases #20

Open
julianladisch opened this issue Sep 25, 2017 · 0 comments
Open

Doesn't write the end of the input file in some cases #20

julianladisch opened this issue Sep 25, 2017 · 0 comments

Comments

@julianladisch
Copy link

i++ in https://github.com/openSUSE/imagewriter/blob/531d36b/Platform.cpp#L112 causes the end of the input file not to be written in some cases.

How to reproduce:

# write 3 MB plus 1 byte of zeroes
sudo dd if=/dev/zero of=/dev/sdb bs=3145729 count=1
# create 3 MB containing \xaa\x55 and 1 byte with character a
printf %3145728sa | sed 's/  /\xaa\x55/g' > a.iso
imagewriter -d /dev/sdb -f a.iso
# read the byte after 3 MB
sudo dd status=none if=/dev/sdb bs=1 skip=3145728 count=1

Expected result: a
The actual result is a null byte.

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

No branches or pull requests

1 participant