From: Martin Mares Date: Sat, 3 Mar 2001 22:50:29 +0000 (+0000) Subject: Moved fp_hash() to index.h. X-Git-Tag: holmes-import~1532 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=6feb8c7ee6a8870ff6bba6265a8f0a5bf5b29c7e;p=libucw.git Moved fp_hash() to index.h. --- diff --git a/lib/index.h b/lib/index.h index 97ce26a8..d484ee8e 100644 --- a/lib/index.h +++ b/lib/index.h @@ -86,6 +86,12 @@ struct fingerprint { void fingerprint(byte *string, struct fingerprint *fp); +static inline u32 +fp_hash(struct fingerprint *fp) +{ + return (fp->hash[0] << 24) | (fp->hash[1] << 16) | (fp->hash[2] << 8) | fp->hash[3]; +} + /* Reading of tagged text (Unicode values, tags mapped to 0x80000000 and higher) */ #define GET_TAGGED_CHAR(p,u) do { \