help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-bash] Best way to suppress the error message in $(< nonexisten


From: Peng Yu
Subject: Re: [Help-bash] Best way to suppress the error message in $(< nonexistent_file)
Date: Wed, 28 Nov 2018 09:56:30 -0600

> $ echo >&-
> -bash: echo: write error: Bad file descriptor
>
> So an application using this descriptor may eg. crash.

I don't quite understand. Why this command does not cause any error?

{ x=$( <doesnotexist) ;} 2>&-

-- 
Regards,
Peng



reply via email to

[Prev in Thread] Current Thread [Next in Thread]