I have seen some problems using XMODEM to transfer text files in adhoc network mode, and don't know what would be causing this. In any case, what I've been using is a program called netcat (nc), which is built into Linux and OS/X, and can be downloaded for Windows (install in \windows\system32).
nc is a simple terminal program - if your matchport IP is 169.254.0.10, you invoke from a Windows command shell (Start Run Cmd) with
nc 169.254.0.10 10001
From there, it's like using telnet in line mode. First clear your flash buffer with 'zc', then invoke the SRV-1 line editor with 'E', then enter 'i' to insert text, then paste your program into the window, then hit ESC to exit the insert mode, and 'x' to exit the editor. Use 'zd' to confirm the contents of the flash buffer, then try to run your program ('Q').
Let me know whether this resolves the problem.
netcat docs -
http://www.vulnwatch.org/netcat/readment.txt netcat download -
http://www.vulnwatch.org/netcat/nc111nt.zip