mirror of
https://github.com/vgough/encfs.git
synced 2024-11-22 07:53:31 +01:00
merge patch from issue 102
git-svn-id: http://encfs.googlecode.com/svn/trunk@69 db9cf616-1c43-0410-9cb8-a902689de0d6
This commit is contained in:
parent
b20b71a97c
commit
b4f090d564
@ -80,7 +80,7 @@ void changeBase2Inline(unsigned char *src, int srcLen,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// we have at least one value that can be output
|
// we have at least one value that can be output
|
||||||
char outVal = work & mask;
|
unsigned char outVal = work & mask;
|
||||||
work >>= dst2Pow;
|
work >>= dst2Pow;
|
||||||
workBits -= dst2Pow;
|
workBits -= dst2Pow;
|
||||||
|
|
||||||
@ -96,8 +96,15 @@ void changeBase2Inline(unsigned char *src, int srcLen,
|
|||||||
*outLoc++ = outVal;
|
*outLoc++ = outVal;
|
||||||
|
|
||||||
// we could have a partial value left in the work buffer..
|
// we could have a partial value left in the work buffer..
|
||||||
if(workBits && outputPartialLastByte)
|
if(outputPartialLastByte)
|
||||||
*outLoc = work & mask;
|
{
|
||||||
|
while(workBits > 0)
|
||||||
|
{
|
||||||
|
*outLoc++ = work & mask;
|
||||||
|
work >>= dst2Pow;
|
||||||
|
workBits -= dst2Pow;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user