fix ambiguity
This commit is contained in:
@@ -179,7 +179,7 @@ namespace crypto {
|
|||||||
|
|
||||||
/// convert integer to binary of given size
|
/// convert integer to binary of given size
|
||||||
inline std::string toBinary(unsigned long data, int bytes=2) {
|
inline std::string toBinary(unsigned long data, int bytes=2) {
|
||||||
std::string res('\0', bytes);
|
std::string res(bytes, '\0');
|
||||||
for (int i(0); i<bytes; ++i) {
|
for (int i(0); i<bytes; ++i) {
|
||||||
res[i] = std::string::value_type(data&0xff);
|
res[i] = std::string::value_type(data&0xff);
|
||||||
data>>=8;
|
data>>=8;
|
||||||
|
Reference in New Issue
Block a user