mingw: Fix compile error

pull/1079/head
Tatsuhiro Tsujikawa 2017-11-16 19:36:59 +09:00
parent 5e7976af89
commit a005f29448
1 changed files with 7 additions and 6 deletions

View File

@ -4,6 +4,7 @@
#include "crypto_hash.h" #include "crypto_hash.h"
#include "crypto_endian.h" #include "crypto_endian.h"
#include "a2functional.h"
#include <cstring> #include <cstring>
#include <stdexcept> #include <stdexcept>
@ -1055,22 +1056,22 @@ std::unique_ptr<Algorithm> crypto::hash::create(Algorithms algo)
{ {
switch (algo) { switch (algo) {
case algoMD5: case algoMD5:
return make_unique<MD5>(); return aria2::make_unique<MD5>();
case algoSHA1: case algoSHA1:
return make_unique<SHA1>(); return aria2::make_unique<SHA1>();
case algoSHA224: case algoSHA224:
return make_unique<SHA224>(); return aria2::make_unique<SHA224>();
case algoSHA256: case algoSHA256:
return make_unique<SHA256>(); return aria2::make_unique<SHA256>();
case algoSHA384: case algoSHA384:
return make_unique<SHA384>(); return aria2::make_unique<SHA384>();
case algoSHA512: case algoSHA512:
return make_unique<SHA512>(); return aria2::make_unique<SHA512>();
default: default:
throw std::domain_error("Invalid hash algorithm"); throw std::domain_error("Invalid hash algorithm");