hash.h: fix std::vector access violation.

Signed-off-by: Tom Li <tomli@tomli.me>
This commit is contained in:
Tom Li 2019-01-04 01:52:54 +08:00
parent a5a1d6190c
commit 538d26900b
No known key found for this signature in database
GPG Key ID: FAD3EB05E88E8D6D

View File

@ -48,7 +48,7 @@ public:
virtual ~hash_proc() {}
void eat (const std::vector<byte>&a) {
return eat (& (a[0]), & (a[a.size()]));
return eat (a.data(), a.data() + a.size());
}
typedef std::map<std::string, factoryof<hash_proc>*> suite_t;