diff --git a/.gitignore b/.gitignore index 549266e..5ec8a1d 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ build etc/clumsy.aps obj_vs obj_ninja +obj_gmake diff --git a/genie.lua b/genie.lua index 735e8f1..f991124 100644 --- a/genie.lua +++ b/genie.lua @@ -62,7 +62,7 @@ solution('clumsy') '-Wno-missing-field-initializers', '--std=c99' }) - objdir('obj_ninja') + objdir('obj_'..MINGW_ACTION) configuration("vs*") defines({"_CRT_SECURE_NO_WARNINGS"}) diff --git a/scripts/send_udp_nums.py b/scripts/send_udp_nums.py index a4cdf1c..e32a78a 100644 --- a/scripts/send_udp_nums.py +++ b/scripts/send_udp_nums.py @@ -9,6 +9,8 @@ from time import sleep from sys import argv, exit +NCAT_EXE = r'C:\Bin\nmap-7.91\ncat' + if __name__ == '__main__': parser = argparse.ArgumentParser(description='ncat num sender') parser.add_argument('host', type=str) @@ -18,17 +20,17 @@ parser.add_argument('--tcp', help='use tcp instead of udp', action='store_true') args = parser.parse_args() - cmd = ['ncat', '-u', '-C', args.host, args.port] + cmd = [NCAT_EXE, '-u', '-C', args.host, args.port] if args.tcp: cmd.remove('-u') ncat = subprocess.Popen(cmd, stdin=subprocess.PIPE) cnt = 1 while True: # send till die - ncat.stdin.write('%s\r\n' % ('-' * (1 + (cnt % 8)))) - #ncat.stdin.write('%d\r\n' % (cnt % 100)) + ncat.stdin.write( ('%s\r\n' % ('-' * (1 + (cnt % 8)))).encode() ) + ncat.stdin.flush() cnt += 1 - print cnt + print(cnt) if not args.nosleep: sleep(args.sleep/1000.0)