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

Improved implementation of wild copy #128

Merged
merged 1 commit into from Jun 28, 2015
Merged

Conversation

mtopolnik
Copy link

As discussed in #126.

@Cyan4973
Copy link
Member

This version still requires some clean up to at least pass compilation tests with less warnings.
Then it will become easier to concentrate on critical memory boundaries issues.

Cyan4973 added a commit that referenced this pull request Jun 28, 2015
Improved implementation of wild copy
@Cyan4973 Cyan4973 merged commit 5578d20 into lz4:wildcopy Jun 28, 2015
@mtopolnik mtopolnik deleted the wildcopy branch June 28, 2015 11:24
@mtopolnik
Copy link
Author

I did try to correct the const-ignoring casts, but on my side i do not get these warnings. Unfortunately I didn't catch all the places where const needs to be added.

@mtopolnik
Copy link
Author

Some notes: i couldn't reproduce the segfault even after testing my code against various files on the file system. However, I learned that in some cases it is possible to get segfault for unaligned pointer derefence---and that's something my code is guilty of. If you don't mind, I might create another PR just to be able to see the build errors from your CI system and perhaps manage to remove the errors.

@Cyan4973
Copy link
Member

Sure, the wildcopy branch is yours to use. I will refrain from doing any change to it, in an effort to avoid repository desynchronisation.

For information, my experience was reverse as yours : I couldn't make this version work, on any file. It would always segfault during decompression. Strange we end up with so different behaviors...

Also, do you use the same compilations flags as suggested within the Makefile, or do you use your own ?

@mtopolnik
Copy link
Author

I'm building on Mac, that could be key. All I do is make && make install, then go use it from the cmdline. I contacted my colleague who is an expert in C (unlike me) so I'll try to heed his advice on how to make the code safer.

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.

None yet

2 participants