From: Alexey Kodanev <alexey.kodanev@oracle.com>
To: ltp@lists.linux.it
Subject: [LTP] new ltp lib doesn't print actual error
Date: Thu, 16 Jun 2016 11:46:17 +0300 [thread overview]
Message-ID: <57626759.9020707@oracle.com> (raw)
In-Reply-To: <488657345.6790022.1466011700050.JavaMail.zimbra@redhat.com>
Hi,
On 06/15/2016 08:28 PM, Jan Stancek wrote:
>
>
>
> ----- Original Message -----
>> From: "Alexey Kodanev" <alexey.kodanev@oracle.com>
>> To: ltp@lists.linux.it
>> Sent: Wednesday, 15 June, 2016 7:08:11 PM
>> Subject: [LTP] new ltp lib doesn't print actual error
>>
>> Hi,
>>
>> When running a test with the new LTP lib, noticed that if some error
>> occurs in a library (tst_tmpdir.c), it'll print the same message:
>>
>> TMPDIR=/usr ./creat01
>> tst_tmpdir.c:155: BROK: Non-NULL cleanup in newlib!
>>
>> but should be:
>> TMPDIR=/usr ./creat01
>> tst_tmpdir.c:155: BROK: tst_tmpdir: mkdtemp(/usr/creF5DhMS) failed: EACCES
>>
>>
>> May be we should remove the strict check in tst_res.c? Otherwise we
>> don't see the actual error.
> Or turn it into warning, so that we get both failures. tst_tmpdir() needs
> a fix to not pass cleanup function for newlib testcases.
>
> diff --git a/lib/tst_res.c b/lib/tst_res.c
> index b388d0d2e516..ab9759b9263b 100644
> --- a/lib/tst_res.c
> +++ b/lib/tst_res.c
> @@ -548,8 +548,8 @@ void tst_brkm_(const char *file, const int lineno, int ttype,
>
> if (tst_test) {
> if (func) {
> - tst_brk_(file, lineno, TBROK,
> - "Non-NULL cleanup in newlib!");
> + tst_resm(TWARN, "Non-NULL cleanup in newlib! %s:%d",
> + file, lineno);
> }
>
> tst_brk_(file, lineno, ttype, "%s", tmesg);
OK, we can do that, I just thought why we need to print it as it's not
related to the test...
Best regards,
Alexey
next prev parent reply other threads:[~2016-06-16 8:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-15 17:08 [LTP] new ltp lib doesn't print actual error Alexey Kodanev
2016-06-15 17:28 ` Jan Stancek
2016-06-16 8:46 ` Alexey Kodanev [this message]
2016-06-20 12:17 ` Cyril Hrubis
2016-06-20 15:58 ` Alexey Kodanev
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=57626759.9020707@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.