1
0
mirror of https://github.com/Melon-Bread/EagleJab synced 2024-11-24 20:28:19 -05:00

Added IP Dialog & Sent Confirmation

This commit is contained in:
Rain Clark 2015-04-28 22:03:21 -04:00
parent 360dc1ecc7
commit bcb0d73a43

View File

@ -1,9 +1,10 @@
import os, socket, sys, struct
#!/usr/bin/env python
import os, socket, sys, struct, easygui
statinfo = os.stat(sys.argv[1])
fbiinfo = struct.pack('!q', statinfo.st_size)
p = sys.argv[1]
dsip = raw_input('Enter IP: ')
dsip = easygui.enterbox("Enter 3DS' IP:", "FalconPunch", "192.168.1.1")
file = open(p, "rb")
sock = socket.socket()
@ -14,6 +15,7 @@ sock.send(fbiinfo)
while True:
chunk = file.read(16384)
if not chunk:
easygui.msgbox("Sent " + p + " to the 3DS", "FalconPunch")
break # EOF
sock.sendall(chunk)