Bug 125345 - Define SHA1 hash size in SHA1.h and use it at various places.
Summary: Define SHA1 hash size in SHA1.h and use it at various places.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-06 06:32 PST by Laszlo Vidacs
Modified: 2013-12-06 10:56 PST (History)
5 users (show)

See Also:


Attachments
Patch (5.69 KB, patch)
2013-12-06 06:45 PST, Laszlo Vidacs
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Laszlo Vidacs 2013-12-06 06:32:05 PST
SHA1 size is used at various places but usually defined as a local variable. A common constant in SHA1.h used by all parties would be a better solution.
Comment 1 Laszlo Vidacs 2013-12-06 06:45:34 PST
Created attachment 218593 [details]
Patch
Comment 2 Anders Carlsson 2013-12-06 08:49:21 PST
Comment on attachment 218593 [details]
Patch

I like this change, but could you also make computeHash take an std::array<uint8_t, hashSize>. There's no need for it to take a Vector.
Comment 3 WebKit Commit Bot 2013-12-06 10:51:40 PST
Comment on attachment 218593 [details]
Patch

Clearing flags on attachment: 218593

Committed r160228: <http://trac.webkit.org/changeset/160228>
Comment 4 WebKit Commit Bot 2013-12-06 10:56:36 PST
All reviewed patches have been landed.  Closing bug.