From 2f5355f76a8168bc504cba8237f0825fc181fce8 Mon Sep 17 00:00:00 2001 From: Kotresh HR Date: Wed, 1 Jul 2015 12:06:42 +0530 Subject: libgfchangelog: Fix example programs Incorporate the new API 'gf_changelog_init' introduced in libgfchangelog which should be called before 'gf_changelog_register'. Change-Id: I10a9dd5ff3ecc64fd61dcb6b1aa53739e0bdeedd BUG: 1238063 Signed-off-by: Kotresh HR Reviewed-on: http://review.gluster.org/11479 Tested-by: NetBSD Build System Reviewed-by: Venky Shankar Tested-by: Gluster Build System --- xlators/features/changelog/lib/examples/c/get-changes.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'xlators/features/changelog/lib/examples/c/get-changes.c') diff --git a/xlators/features/changelog/lib/examples/c/get-changes.c b/xlators/features/changelog/lib/examples/c/get-changes.c index 0b2808c7e35..ef766c566b6 100644 --- a/xlators/features/changelog/lib/examples/c/get-changes.c +++ b/xlators/features/changelog/lib/examples/c/get-changes.c @@ -39,6 +39,12 @@ main (int argc, char ** argv) ssize_t changes = 0; char fbuf[PATH_MAX] = {0,}; + ret = gf_changelog_init (NULL); + if (ret) { + handle_error ("Init failed"); + goto out; + } + /* get changes for brick "/home/vshankar/export/yow/yow-1" */ ret = gf_changelog_register ("/export/z1/zwoop", "/tmp/scratch", "/tmp/change.log", 9, 5); -- cgit