* [PATCH] fstests: fix _repair_scratch_fs error reporting
@ 2019-05-28 12:08 Amir Goldstein
2019-05-29 13:37 ` zhangyi (F)
0 siblings, 1 reply; 2+ messages in thread
From: Amir Goldstein @ 2019-05-28 12:08 UTC (permalink / raw)
To: Eryu Guan; +Cc: zhangyi, fstests
_dump_err2() helper was introduced over two years ago and it broke
the error reporting from _repair_scratch_fs.
Every test that runs:
_repair_scratch_fs >> $seqres.full
and expect to fail if anything is written to stderr is not working
as intended.
Spotted-by: zhangyi (F) <yi.zhang@huawei.com>
Signed-off-by: Amir Goldstein <amir73il@gmail.com>
---
Eryu,
This bug was found by zhangyi while working on fsck.overlay patches,
but it affects all filesystems. I just re-found zhangyi's fix while
going through some old notes.
Amir.
common/rc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/common/rc b/common/rc
index 17b89d5d..e78e0920 100644
--- a/common/rc
+++ b/common/rc
@@ -98,7 +98,7 @@ _dump_err_cont()
_dump_err2()
{
_err_msg="$*"
- >2& echo "$_err_msg"
+ >&2 echo "$_err_msg"
}
_log_err()
--
2.17.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] fstests: fix _repair_scratch_fs error reporting
2019-05-28 12:08 [PATCH] fstests: fix _repair_scratch_fs error reporting Amir Goldstein
@ 2019-05-29 13:37 ` zhangyi (F)
0 siblings, 0 replies; 2+ messages in thread
From: zhangyi (F) @ 2019-05-29 13:37 UTC (permalink / raw)
To: Amir Goldstein, Eryu Guan; +Cc: fstests
On 2019/5/28 20:08, Amir Goldstein Wrote:
> _dump_err2() helper was introduced over two years ago and it broke
> the error reporting from _repair_scratch_fs.
>
> Every test that runs:
> _repair_scratch_fs >> $seqres.full
>
> and expect to fail if anything is written to stderr is not working
> as intended.
>
> Spotted-by: zhangyi (F) <yi.zhang@huawei.com>
> Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Thanks for re-post it.
Reviewed-by: zhangyi (F) <yi.zhang@huawei.com>
Thanks
Yi.
> ---
>
> Eryu,
>
> This bug was found by zhangyi while working on fsck.overlay patches,
> but it affects all filesystems. I just re-found zhangyi's fix while
> going through some old notes.
>
> Amir.
>
> common/rc | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/common/rc b/common/rc
> index 17b89d5d..e78e0920 100644
> --- a/common/rc
> +++ b/common/rc
> @@ -98,7 +98,7 @@ _dump_err_cont()
> _dump_err2()
> {
> _err_msg="$*"
> - >2& echo "$_err_msg"
> + >&2 echo "$_err_msg"
> }
>
> _log_err()
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-05-29 13:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-28 12:08 [PATCH] fstests: fix _repair_scratch_fs error reporting Amir Goldstein
2019-05-29 13:37 ` zhangyi (F)
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.