Whamcloud - gitweb
b=2683
authorzab <zab>
Sat, 7 Feb 2004 00:37:01 +0000 (00:37 +0000)
committerzab <zab>
Sat, 7 Feb 2004 00:37:01 +0000 (00:37 +0000)
In the echo_client's prep/commit test ioo_bufcnt could be out of
sync with the npages given to obd_{prep,commit}rw.

lustre/obdecho/echo_client.c

index 87b2f92..fa591b2 100644 (file)
@@ -864,7 +864,6 @@ static int echo_client_prep_commit(struct obd_export *exp, int rw,
                 GOTO(out, ret = -ENOMEM);
 
         obdo_to_ioobj(oa, &ioo);
-        ioo.ioo_bufcnt = npages;
 
         off = offset;
 
@@ -879,6 +878,7 @@ static int echo_client_prep_commit(struct obd_export *exp, int rw,
 
                 /* XXX this can't be the best.. */
                 memset(oti, 0, sizeof(*oti));
+                ioo.ioo_bufcnt = npages;
 
                 ret = obd_preprw(rw, exp, oa, 1, &ioo, npages, rnb, lnb, oti);
                 if (ret != 0)