From: Alexey Kodanev <alexey.kodanev@oracle.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] syscalls: close open files in cleanup
Date: Tue, 22 Mar 2016 12:11:18 +0300 [thread overview]
Message-ID: <56F10C36.40805@oracle.com> (raw)
In-Reply-To: <20160321130439.GA1022@rei>
Hi,
On 03/21/2016 04:04 PM, Cyril Hrubis wrote:
> Hi!
>> NFS creates special .nfs* files when test file was removed and
>> left open. In that case, tst_rmdir() fails to remove test dirs.
>>
>> Close left open files in cleanup and replace some of safe_open()
>> calls with safe_file_printf() ones for test files which fd won't
>> be used in a test.
> I would be closing the file descriptors only if they were initialized
> with value > 0, since otherwise there would be misleading failing close
> in the strace in case that some setup step prior to the SAFE_OPEN()
> failed.
Added checks and applied.
Thanks,
Alexey
> Otherwise it looks good.
>
prev parent reply other threads:[~2016-03-22 9:11 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-18 13:57 [LTP] [PATCH] syscalls: close open files in cleanup Alexey Kodanev
2016-03-21 13:04 ` Cyril Hrubis
2016-03-22 9:11 ` Alexey Kodanev [this message]
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=56F10C36.40805@oracle.com \
--to=alexey.kodanev@oracle.com \
--cc=ltp@lists.linux.it \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.