From 4df7a3c4888fbf1e1f84246aeac92af396879ce5 Mon Sep 17 00:00:00 2001 From: Santosh Kumar Pradhan Date: Wed, 22 May 2013 15:26:04 +0530 Subject: xlator: NULL terminate volume_options struct Problem: volume_options struct for open-behind and quick-read xlators were not NULL terminated. Fix: Make them NULL terminated. Change-Id: I2615a1f15c6e5674030a219a99ddf91596bf346b BUG: 965995 Signed-off-by: Santosh Kumar Pradhan Reviewed-on: http://review.gluster.org/5064 Reviewed-by: Kaleb KEITHLEY Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- xlators/performance/open-behind/src/open-behind.c | 11 ++++++----- xlators/performance/quick-read/src/quick-read.c | 1 + 2 files changed, 7 insertions(+), 5 deletions(-) (limited to 'xlators/performance') diff --git a/xlators/performance/open-behind/src/open-behind.c b/xlators/performance/open-behind/src/open-behind.c index e23a23325..b405b94cd 100644 --- a/xlators/performance/open-behind/src/open-behind.c +++ b/xlators/performance/open-behind/src/open-behind.c @@ -922,15 +922,16 @@ struct volume_options options[] = { { .key = {"use-anonymous-fd"}, .type = GF_OPTION_TYPE_BOOL, .default_value = "yes", - .description = "For read operations, use anonymous FD when " - "original FD is open-behind and not yet opened in the backend.", + .description = "For read operations, use anonymous FD when " + "original FD is open-behind and not yet opened in the backend.", }, { .key = {"lazy-open"}, .type = GF_OPTION_TYPE_BOOL, .default_value = "yes", - .description = "Perform open in the backend only when a necessary " - "FOP arrives (e.g writev on the FD, unlink of the file). When option " - "is disabled, perform backend open right after unwinding open().", + .description = "Perform open in the backend only when a necessary " + "FOP arrives (e.g writev on the FD, unlink of the file). When option " + "is disabled, perform backend open right after unwinding open().", }, + { .key = {NULL} } }; diff --git a/xlators/performance/quick-read/src/quick-read.c b/xlators/performance/quick-read/src/quick-read.c index c2ddd0df0..445ea8658 100644 --- a/xlators/performance/quick-read/src/quick-read.c +++ b/xlators/performance/quick-read/src/quick-read.c @@ -1143,4 +1143,5 @@ struct volume_options options[] = { .max = 1 * GF_UNIT_KB * 1000, .default_value = "64KB", }, + { .key = {NULL} } }; -- cgit