]> git.proxmox.com Git - mirror_edk2.git/blobdiff - AppPkg/Applications/Python/Python-2.7.2/Demo/sockets/rpython.py
edk2: Remove AppPkg, StdLib, StdLibPrivateInternalFiles
[mirror_edk2.git] / AppPkg / Applications / Python / Python-2.7.2 / Demo / sockets / rpython.py
diff --git a/AppPkg/Applications/Python/Python-2.7.2/Demo/sockets/rpython.py b/AppPkg/Applications/Python/Python-2.7.2/Demo/sockets/rpython.py
deleted file mode 100644 (file)
index a28de1d..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-#! /usr/bin/env python\r
-\r
-# Remote python client.\r
-# Execute Python commands remotely and send output back.\r
-\r
-import sys\r
-import string\r
-from socket import *\r
-\r
-PORT = 4127\r
-BUFSIZE = 1024\r
-\r
-def main():\r
-    if len(sys.argv) < 3:\r
-        print "usage: rpython host command"\r
-        sys.exit(2)\r
-    host = sys.argv[1]\r
-    port = PORT\r
-    i = string.find(host, ':')\r
-    if i >= 0:\r
-        port = string.atoi(port[i+1:])\r
-        host = host[:i]\r
-    command = string.join(sys.argv[2:])\r
-    s = socket(AF_INET, SOCK_STREAM)\r
-    s.connect((host, port))\r
-    s.send(command)\r
-    s.shutdown(1)\r
-    reply = ''\r
-    while 1:\r
-        data = s.recv(BUFSIZE)\r
-        if not data: break\r
-        reply = reply + data\r
-    print reply,\r
-\r
-main()\r