From: Cristian Greco <cristian@regolo.cc>(by way of Cristian Greco <cristian@regolo.cc>)
To: Caspar Zhang <czhang@redhat.com>
Subject: Re: [LTP] [PATCH] syscalls: acct01: fix testcases [was: Re: [PATCH] Add tst_require_root to acct01 testcase.]
Date: Thu, 3 Mar 2011 18:42:23 +0100 [thread overview]
Message-ID: <20110303184223.23ac427e@regolo> (raw)
In-Reply-To: <4D6FCCF7.2010101@redhat.com>
[-- Attachment #1.1: Type: text/plain, Size: 1360 bytes --]
On Fri, 04 Mar 2011 01:16:39 +0800
Caspar Zhang <czhang@redhat.com> wrote:
> On 01/21/2011 04:28 PM, Garrett Cooper wrote:
> > On Thu, Jan 20, 2011 at 5:30 AM, Cristian Greco <cristian@regolo.cc> wrote:
> >> > Hi,
> >> >
> >> > [ please keep CC as I'm not currently subscribed to the list ]
> >> >
> >> > please find attached a small fix to check for root privileges in
> >> > acct(2) testcase (syscalls/acct/acct01.c).
> > Thanks for spotting the issue. I've fixed it, added a few more
> > testcases, and discovered what appears to be a kernel bug on 2.6.34
> > (acct("/tmp/does/not/exist") should fail with == -1 and errno ==
> > ENOTDIR) :)...
> > Cheers,
> > -Garrett
>
> a follow-up fix for http://article.gmane.org/gmane.linux.ltp/13576 .
> In fact, it's not a kernel bug of ENOTDIR's failure. ENOTDIR means that
> you setup a string as directory in argument, but it is actually a file.
> The patch fixes this failure. The result of given path
> /tmp/does/not/exist should be expected as ENOENT.
>
> And also, there is a mistake in EPERM case, to restore the permissions,
> SAFE_SETUID should be used instead of SAFE_SETGID, else it will never
> recover the permissions.
Hi Caspar,
I noticed the error today but did not have time to work on it.
Thanks for your work!
--
Cristian Greco
GPG key ID: 0xCF4D32E4
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
[-- Attachment #2: Type: text/plain, Size: 429 bytes --]
------------------------------------------------------------------------------
Free Software Download: Index, Search & Analyze Logs and other IT data in
Real-Time with Splunk. Collect, index and harness all the fast moving IT data
generated by your applications, servers and devices whether physical, virtual
or in the cloud. Deliver compliance at lower cost and gain new business
insights. http://p.sf.net/sfu/splunk-dev2dev
[-- Attachment #3: Type: text/plain, Size: 155 bytes --]
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
next prev parent reply other threads:[~2011-03-03 18:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-20 13:30 [LTP] [PATCH] Add tst_require_root to acct01 testcase Cristian Greco
2011-01-21 8:28 ` Garrett Cooper
2011-03-03 17:16 ` [LTP] [PATCH] syscalls: acct01: fix testcases [was: Re: [PATCH] Add tst_require_root to acct01 testcase.] Caspar Zhang
2011-03-03 17:42 ` Cristian Greco [this message]
2011-03-04 9:28 ` Garrett Cooper
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=20110303184223.23ac427e@regolo \
--to=cristian@regolo.cc \
--cc=czhang@redhat.com \
/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