Skip to content

Fix wrong umask calculation in download test#1338

Merged
cvium merged 1 commit intoFlexget:developfrom
danielkza:fix-test-misc-umask
Aug 15, 2016
Merged

Fix wrong umask calculation in download test#1338
cvium merged 1 commit intoFlexget:developfrom
danielkza:fix-test-misc-umask

Conversation

@danielkza
Copy link
Copy Markdown
Contributor

Calculating the umask by subtraction only works by coincidence in some cases. The correct way is to use bitwise operations to unset any bits in the umask from the expected permissions. I found this since I run with umask 077 and the test always failed on my system.

@cvium
Copy link
Copy Markdown
Contributor

cvium commented Aug 15, 2016

Is it only the test or also in the download plugin itself?

@danielkza
Copy link
Copy Markdown
Contributor Author

danielkza commented Aug 15, 2016

Very likely only the test, since it passes with my umask of 077 after the fix without changing the implementation at all.

@cvium cvium merged commit c1fc126 into Flexget:develop Aug 15, 2016
@cvium
Copy link
Copy Markdown
Contributor

cvium commented Aug 15, 2016

Alright, thanks

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