From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pete Zaitcev Subject: [Patch 1/1] Chunk: fix stored checksums Date: Sun, 20 Dec 2009 19:45:01 -0700 Message-ID: <20091220194501.4cd6ad6f@redhat.com> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: Sender: hail-devel-owner@vger.kernel.org List-ID: Content-Type: text/plain; charset="us-ascii" To: Jeff Garzik Cc: Project Hail List Existing code writes checksums of something other than the object data. Fix by summing the object data. Signed-off-by: Pete Zaitcev --- server/object.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) This seems too obvious... Where is the trap? diff -urpN -X dontdiff chunkd-m/server/object.c chunkd-tip/server/object.c --- chunkd-m/server/object.c 2009-12-20 19:06:24.156353635 -0700 +++ chunkd-tip/server/object.c 2009-12-20 19:05:57.130476765 -0700 @@ -195,7 +195,7 @@ bool cli_evt_data_in(struct client *cli, return cli_err(cli, che_InternalError, false); } - SHA1_Update(&cli->out_hash, cli->req_ptr, bytes); + SHA1_Update(&cli->out_hash, p, bytes); cli->out_len -= bytes; p += bytes;