From 49eb11e8347cd8e403f1f2db10b22ef202b31cb4 Mon Sep 17 00:00:00 2001 From: eestolan Date: Wed, 28 Nov 2007 06:12:30 +0000 Subject: [PATCH] Added a cheap hack for testing purposes. It's commented out via a #define CHEAP_HACK 0 git-svn-id: https://ceph.svn.sf.net/svnroot/ceph@2130 29311d96-e01e-0410-9327-a35deaab8ce9 --- trunk/ceph/client/SyntheticClient.cc | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/trunk/ceph/client/SyntheticClient.cc b/trunk/ceph/client/SyntheticClient.cc index 364da42a9a050..dfdc17a1fcde7 100644 --- a/trunk/ceph/client/SyntheticClient.cc +++ b/trunk/ceph/client/SyntheticClient.cc @@ -1684,6 +1684,13 @@ int SyntheticClient::write_file(string& fn, int size, int wrsize) // size is i dout(5) << "writing to " << fn << " fd " << fd << dendl; if (fd < 0) return fd; +#define CHEAP_HACK 0 +#if CHEAP_HACK + // START temporary hack piece 1 --Esteban + for (int foo = 0; foo < 10; ++foo) { + // END temporary hack piece 1 --Esteban +#endif + for (unsigned i=0; iwrite(fd, buf, wrsize, i*wrsize); } - +#if CHEAP_HACK + // START temporary hack piece 2--Esteban + } + sleep(5); + // END temporary hack piece 2 --Esteban +#endif + client->close(fd); delete[] buf; -- 2.39.5