mirror of
https://github.com/qpdf/qpdf.git
synced 2025-02-02 11:58:25 +00:00
avoid low order bits of random just in case it's rand
git-svn-id: svn+q:///qpdf/trunk@815 71b93d88-0707-0410-a8cf-f5a4172ac649
This commit is contained in:
parent
62c5fa6b48
commit
5c253d1c13
@ -121,7 +121,7 @@ Pl_AES_PDF::initializeVector()
|
|||||||
srandom(seed);
|
srandom(seed);
|
||||||
for (unsigned int i = 0; i < this->buf_size; ++i)
|
for (unsigned int i = 0; i < this->buf_size; ++i)
|
||||||
{
|
{
|
||||||
this->cbc_block[i] = (unsigned char)(random() & 0xff);
|
this->cbc_block[i] = (unsigned char)((random() & 0xff0) >> 4);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user