Tarantool development patches archive
 help / color / mirror / Atom feed
From: Олег <olegrok@tarantool.org>
To: tarantool-patches@freelists.org
Subject: [tarantool-patches] Re: [PATCH v2] fio: introduce utime function
Date: Mon, 8 Jul 2019 18:52:24 +0300	[thread overview]
Message-ID: <0539c600-d652-fa15-3c3f-7e1cd6fb0dee@tarantool.org> (raw)
In-Reply-To: <20190708145110.rauvydnpn3c6hhqq@esperanza>


Thanks! My bad. I really missed it.

Please apply following diff to my patch.

diff --git a/src/lua/fio.c b/src/lua/fio.c
index 55fa66762..48e2f8eb3 100644
--- a/src/lua/fio.c
+++ b/src/lua/fio.c
@@ -709,7 +709,7 @@ lbox_fio_utime(struct lua_State *L)
      const char *pathname = lua_tostring(L, 1);
      double atime = lua_tonumber(L, 2);
      double mtime = lua_tonumber(L, 3);
-    return lbox_fio_pushbool(L, coio_utime(pathname, atime, mtime) == 0);
+    return lbox_fio_pushbool(L, coio_utime(pathname, mtime, atime) == 0);
  }

  void
diff --git a/test/app/fio.result b/test/app/fio.result
index 3663560ae..34f58d6bc 100644
--- a/test/app/fio.result
+++ b/test/app/fio.result
@@ -1083,11 +1083,11 @@ fio.utime('newfile', 1, 2)
  ...
  fh:stat().atime == 1
  ---
-- false
+- true
  ...
  fh:stat().mtime == 2
  ---
-- false
+- true
  ...
  fio.utime('newfile', 3)
  ---


08.07.2019 17:51, Vladimir Davydov wrote:
 > On Fri, Jul 05, 2019 at 10:07:03PM +0300, Oleg Babin wrote:
 >> +fio.utime('newfile', 0, 0)
 >> +---
 >> +- true
 >> +...
 >> +fh:stat().atime == 0
 >> +---
 >> +- true
 >> +...
 >> +fh:stat().mtime == 0
 >> +---
 >> +- true
 >> +...
 >> +fio.utime('newfile', 1, 2)
 >> +---
 >> +- true
 >> +...
 >> +fh:stat().atime == 1
 >> +---
 >> +- false
 >> +...
 >> +fh:stat().mtime == 2
 >> +---
 >> +- false
 >> +...
 >
 > ???
 >
 > Looks like you mixed atime with mtime. Please fix.
 >

  reply	other threads:[~2019-07-08 15:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-05 19:07 Oleg Babin
2019-07-08 14:51 ` Vladimir Davydov
2019-07-08 15:52   ` Олег [this message]
2019-07-09  8:55     ` [tarantool-patches] " Vladimir Davydov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0539c600-d652-fa15-3c3f-7e1cd6fb0dee@tarantool.org \
    --to=olegrok@tarantool.org \
    --cc=tarantool-patches@freelists.org \
    --subject='[tarantool-patches] Re: [PATCH v2] fio: introduce utime function' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox