From: chrubis@suse.cz
To: DAN LI <li.dan@cn.fujitsu.com>
Cc: ltp-list@lists.sourceforge.net
Subject: Re: [LTP] [PATCH 2/2 v3] quotactl/quotactl02.c: create a case to test basic flags of quotactl(2)
Date: Mon, 2 Sep 2013 16:57:49 +0200 [thread overview]
Message-ID: <20130902145749.GB26252@rei> (raw)
In-Reply-To: <521EB988.7000407@cn.fujitsu.com>
Hi!
> +static void setup(void)
> +{
> +
> + tst_require_root(NULL);
> +
> + TEST_PAUSE;
> +
> + tst_tmpdir();
> +
> + SAFE_MKDIR(cleanup, mntpoint, 0755);
> +
> + uid = 0;
One last nit. What is the point of setting uid to -1 first and then
changing it here to 0? Can't we just set it to 0 from the start?
> + tst_mkfs(NULL, block_dev, "xfs", NULL);
> +
> + if (mount(block_dev, mntpoint, "xfs", 0, "uquota") < 0)
> + tst_brkm(TFAIL | TERRNO, NULL, "mount(2) fail");
> +
> +}
--
Cyril Hrubis
chrubis@suse.cz
------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
next prev parent reply other threads:[~2013-09-02 14:57 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <521C4688.9020305@cn.fujitsu.com>
[not found] ` <521C46FB.7020308@cn.fujitsu.com>
2013-08-27 12:51 ` [LTP] [PATCH 2/2 v2] quotactl/quotactl02.c: create a case to test basic flags of quotactl(2) chrubis
[not found] ` <521D710C.8030609@cn.fujitsu.com>
2013-08-28 9:38 ` chrubis
[not found] ` <521DC969.3090103@cn.fujitsu.com>
2013-08-28 9:58 ` chrubis
[not found] ` <521EB988.7000407@cn.fujitsu.com>
2013-09-02 14:57 ` chrubis [this message]
2013-09-04 12:03 ` [LTP] [PATCH 1/2 v2] Check if xfs quota is available chrubis
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=20130902145749.GB26252@rei \
--to=chrubis@suse.cz \
--cc=li.dan@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