fix ambiguity

master
Marc Wäckerlin 9 years ago
parent b60e52fa4f
commit b1d7d4bd2c
  1. 2
      src/cryptaux.hxx

@ -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;

Loading…
Cancel
Save