Signed-off-by: Mi Jinlong <mijinlong@xxxxxxxxxxxxxx> --- nfs4.1/nfs4client.py | 1 + nfs4.1/server41tests/st_create_session.py | 15 +++++++++++++++ 2 files changed, 16 insertions(+), 0 deletions(-) diff --git a/nfs4.1/nfs4client.py b/nfs4.1/nfs4client.py index b517c27..9786bf3 100644 --- a/nfs4.1/nfs4client.py +++ b/nfs4.1/nfs4client.py @@ -404,6 +404,7 @@ class SendChannel(object): class SessionRecord(object): def __init__(self, csr, client): self.sessionid = csr.csr_sessionid + self.seqid = csr.csr_sequence self.client = client self.c = client.c self.cred = client.cred diff --git a/nfs4.1/server41tests/st_create_session.py b/nfs4.1/server41tests/st_create_session.py index 1d02a50..4185aa8 100644 --- a/nfs4.1/server41tests/st_create_session.py +++ b/nfs4.1/server41tests/st_create_session.py @@ -396,3 +396,18 @@ def testNotOnlyOp(t, env): chan_attrs, chan_attrs, 123, []), op.putrootfh()], None) check(res, NFS4ERR_NOT_ONLY_OP) + +def testCsr_sequence(t, env): + """The corresponding result of csa_sequence is csr_sequence, + which MUST be equal to csa_sequence. + + FLAGS: create_session all + CODE: CSESS24 + """ + c = env.c1.new_client(env.testname(t)) + # CREATE_SESSION + chan_attrs = channel_attrs4(0,8192,8192,8192,128,8,[]) + csa_sequence = c.seqid + sess1 = c.create_session(fore_attrs=chan_attrs) + if not nfs4lib.test_equal(sess1.seqid, csa_sequence, "int"): + fail("Server returns bad csr_sequence which not equal to csa_sequence") -- 1.7.4.1 -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html