aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar zfl9 <zfl9.com@gmail.com> 2019-08-30 21:34:56 +0800
committerGravatar zfl9 <zfl9.com@gmail.com> 2019-08-30 21:34:56 +0800
commit792b55737297fd08a6cc30b899d727e3828d4d31 (patch)
tree5e41daa8d47af76db68128764720509193988188
parentadd makefile (diff)
downloaddns2tcp-792b55737297fd08a6cc30b899d727e3828d4d31.tar.gz
dns2tcp-792b55737297fd08a6cc30b899d727e3828d4d31.tar.bz2
dns2tcp-792b55737297fd08a6cc30b899d727e3828d4d31.zip
update dns2tcp.c
-rw-r--r--dns2tcp.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/dns2tcp.c b/dns2tcp.c
index c1f08f7..7267f69 100644
--- a/dns2tcp.c
+++ b/dns2tcp.c
@@ -3,7 +3,18 @@
#include <uv.h>
#undef _GNU_SOURCE
-int main(void) {
- LOGINF("[main] hello, world!");
+static void print_command_help(void) {
+ printf("usage: dns2tcp <-L LISTEN_ADDR> <-R REMOTE_ADDR> [-vVh]\n"
+ " -L <ip#port> udp listen address, it is required\n"
+ " -R <ip#port> tcp server address, it is required\n"
+ " -v print verbose log, default: <disabled>\n"
+ " -V print version number of dns2tcp and exit\n"
+ " -h print help information of dns2tcp and exit\n"
+ "bug report: https://github.com/zfl9/dns2tcp. email: zfl9.com@gmail.com\n"
+ );
+}
+
+int main() {
+ print_command_help();
return 0;
}