diff mbox series

st_flex: fix uid/gid formatting in error message

Message ID 20190722141602.14274-1-tigran.mkrtchyan@desy.de (mailing list archive)
State New, archived
Headers show
Series st_flex: fix uid/gid formatting in error message | expand

Commit Message

Mkrtchyan, Tigran July 22, 2019, 2:16 p.m. UTC
as ffds_user and ffds_group are utf8 encoded string use '%s' when
constructing an error message.

Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
---
 nfs4.1/server41tests/st_flex.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

J. Bruce Fields Aug. 1, 2019, 8:01 p.m. UTC | #1
On Mon, Jul 22, 2019 at 04:16:02PM +0200, Tigran Mkrtchyan wrote:
> as ffds_user and ffds_group are utf8 encoded string use '%s' when
> constructing an error message.

Thanks, applied--sorry for being slow to get to this.

--b.

> 
> Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
> ---
>  nfs4.1/server41tests/st_flex.py | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/nfs4.1/server41tests/st_flex.py b/nfs4.1/server41tests/st_flex.py
> index 335b2c8..f4ac739 100644
> --- a/nfs4.1/server41tests/st_flex.py
> +++ b/nfs4.1/server41tests/st_flex.py
> @@ -313,10 +313,10 @@ def testFlexLayoutTestAccess(t, env):
>      gid_rd = ds.ffds_group
>  
>      if uid_rw == uid_rd:
> -        fail("Expected uid_rd != %i, got %i" % (uid_rd, uid_rw))
> +        fail("Expected uid_rd != %s, got %s" % (uid_rd, uid_rw))
>  
>      if gid_rw != gid_rd:
> -        fail("Expected gid_rd == %i, got %i" % (gid_rd, gid_rw))
> +        fail("Expected gid_rd == %s, got %s" % (gid_rd, gid_rw))
>  
>      res = close_file(sess, fh, stateid=open_stateid)
>      check(res)
> -- 
> 2.21.0
diff mbox series

Patch

diff --git a/nfs4.1/server41tests/st_flex.py b/nfs4.1/server41tests/st_flex.py
index 335b2c8..f4ac739 100644
--- a/nfs4.1/server41tests/st_flex.py
+++ b/nfs4.1/server41tests/st_flex.py
@@ -313,10 +313,10 @@  def testFlexLayoutTestAccess(t, env):
     gid_rd = ds.ffds_group
 
     if uid_rw == uid_rd:
-        fail("Expected uid_rd != %i, got %i" % (uid_rd, uid_rw))
+        fail("Expected uid_rd != %s, got %s" % (uid_rd, uid_rw))
 
     if gid_rw != gid_rd:
-        fail("Expected gid_rd == %i, got %i" % (gid_rd, gid_rw))
+        fail("Expected gid_rd == %s, got %s" % (gid_rd, gid_rw))
 
     res = close_file(sess, fh, stateid=open_stateid)
     check(res)