From da505a63c12ea9be0e783711547fe7bbfecf05ea Mon Sep 17 00:00:00 2001 From: Anand Avati Date: Sat, 23 Jan 2010 13:26:39 +0000 Subject: dht: initialize layout type Instead of relying on CALLOC's zero initialization which happens to be the value of DHT_HASH_TYPE_DM, explicitly set the value Signed-off-by: Anand V. Avati Signed-off-by: Anand V. Avati BUG: 523 (Hash type is not initialized in dht_layout_new) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=523 --- xlators/cluster/dht/src/dht-common.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'xlators/cluster/dht/src/dht-common.h') diff --git a/xlators/cluster/dht/src/dht-common.h b/xlators/cluster/dht/src/dht-common.h index 5a43f9c0682..3997791d69a 100644 --- a/xlators/cluster/dht/src/dht-common.h +++ b/xlators/cluster/dht/src/dht-common.h @@ -50,6 +50,11 @@ struct dht_layout { typedef struct dht_layout dht_layout_t; +typedef enum { + DHT_HASH_TYPE_DM, +} dht_hashfn_type_t; + + struct dht_local { int call_cnt; loc_t loc; -- cgit