From: chrubis@suse.cz
To: Xing Gu <gux.fnst@cn.fujitsu.com>
Cc: ltp-list@lists.sourceforge.net
Subject: Re: [LTP] [PATCH 2/3] utimes/utimes01.c: cleanup
Date: Tue, 17 Jun 2014 16:12:26 +0200 [thread overview]
Message-ID: <20140617141226.GC29117@rei> (raw)
In-Reply-To: <1402627999-11535-2-git-send-email-gux.fnst@cn.fujitsu.com>
Hi!
> -/* History: Porting from Crackerjack to LTP is done by */
> -/* Manas Kumar Nayak maknayak@in.ibm.com> */
I've added this to the header under the Authors.
> - /**
> - * Note (garrcoop):
> - *
> - * If you do NULL directly, then gcc [4.3] will complain when
> - * one specifies -Wnonnull in CPPFLAGS. This is a negative
> - * test, but let's not allow the compiler to complain about
> - * something trivial like this.
> - **/
> - const char *dummy = NULL;
> - TEST(sys_ret = utimes(dummy, tv));
> + if (TEST_ERRNO == tc->exp_errno) {
> + tst_resm(TPASS | TTERRNO, "utimes() failed as expected");
^
I've changed this to "worked as expected"
because the first two testcases
do not fait at all.
Also I may be better to split the test into two files one for positive
tests and one for negative tests because as it is the code does not
check that utimes() actually changed the times and we may add test that
calls utimes() with NULL times, which should set the times to current
time. Adding these changes to the currect code would overcomplicate the
verify function...
Patchset applied, Thanks.
--
Cyril Hrubis
chrubis@suse.cz
------------------------------------------------------------------------------
HPCC Systems Open Source Big Data Platform from LexisNexis Risk Solutions
Find What Matters Most in Your Big Data with HPCC Systems
Open Source. Fast. Scalable. Simple. Ideal for Dirty Data.
Leverages Graph Analysis for Fast Processing & Easy Data Exploration
http://p.sf.net/sfu/hpccsystems
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
next prev parent reply other threads:[~2014-06-17 14:12 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-13 2:53 [LTP] [PATCH 1/3] lib: Add SAFE_CHOWN() Xing Gu
2014-06-13 2:53 ` [LTP] [PATCH 2/3] utimes/utimes01.c: cleanup Xing Gu
2014-06-17 14:12 ` chrubis [this message]
2014-06-13 2:53 ` [LTP] [PATCH 3/3] utimes/utimes01.c: add EPERM and EROFS error value tests Xing Gu
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=20140617141226.GC29117@rei \
--to=chrubis@suse.cz \
--cc=gux.fnst@cn.fujitsu.com \
--cc=ltp-list@lists.sourceforge.net \
/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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox