mirror of
https://github.com/oe7drt/YSFClients.git
synced 2025-12-06 05:32:02 +01:00
Remove the unused debug option.
This commit is contained in:
parent
305f49c13c
commit
42bb42380a
|
|
@ -35,31 +35,20 @@ int main(int argc, char** argv)
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int n = 1U;
|
unsigned int port = ::atoi(argv[1U]);
|
||||||
|
|
||||||
bool debug = false;
|
|
||||||
|
|
||||||
for (; n < argc-1; n++) {
|
|
||||||
if (::strcmp(argv[n], "-d") == 0 || ::strcmp(argv[n], "--debug") == 0) {
|
|
||||||
debug = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
unsigned int port = ::atoi(argv[n]);
|
|
||||||
if (port == 0U) {
|
if (port == 0U) {
|
||||||
::fprintf(stderr, "YSFParrot: invalid port number - %s\n", argv[n]);
|
::fprintf(stderr, "YSFParrot: invalid port number - %s\n", argv[1U]);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
CYSFParrot parrot(port, debug);
|
CYSFParrot parrot(port);
|
||||||
parrot.run();
|
parrot.run();
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
CYSFParrot::CYSFParrot(unsigned int port, bool debug) :
|
CYSFParrot::CYSFParrot(unsigned int port) :
|
||||||
m_port(port),
|
m_port(port)
|
||||||
m_debug(debug)
|
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -22,14 +22,13 @@
|
||||||
class CYSFParrot
|
class CYSFParrot
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CYSFParrot(unsigned int port, bool debug);
|
CYSFParrot(unsigned int port);
|
||||||
~CYSFParrot();
|
~CYSFParrot();
|
||||||
|
|
||||||
void run();
|
void run();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
unsigned int m_port;
|
unsigned int m_port;
|
||||||
bool m_debug;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue