kopia lustrzana https://github.com/xaelsouth/rtl-wmbus
Only print help if no arguments given and stdin is a tty.
rodzic
1928547817
commit
325a2eb8e2
|
@ -1175,7 +1175,7 @@ int main(int argc, char *argv[])
|
||||||
#if WINDOWS_BUILD == 1
|
#if WINDOWS_BUILD == 1
|
||||||
_setmode(_fileno(stdin), _O_BINARY);
|
_setmode(_fileno(stdin), _O_BINARY);
|
||||||
#else
|
#else
|
||||||
if (isatty(0))
|
if (isatty(0) && argc == 1)
|
||||||
{
|
{
|
||||||
// Standard input is a terminal, print help.
|
// Standard input is a terminal, print help.
|
||||||
print_usage(argv[0]);
|
print_usage(argv[0]);
|
||||||
|
|
Ładowanie…
Reference in New Issue