stdin input works now

This commit is contained in:
Hedy Li 2021-07-10 12:41:28 +08:00
parent f5b58ce4ff
commit 38524b2e25
Signed by: hedy
GPG Key ID: B51B5A8D1B176372
1 changed files with 1 additions and 1 deletions

View File

@ -138,7 +138,7 @@ func main() {
var err error
if file == "-" {
stat, _ := os.Stdin.Stat()
if (stat.Mode() & os.ModeCharDevice) == 0 {
if (stat.Mode() & os.ModeCharDevice) != 0 {
fmt.Println("nothing in stdin")
os.Exit(1)
}