summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1994-10-08 19:24:02 (GMT)
committerGuido van Rossum <guido@python.org>1994-10-08 19:24:02 (GMT)
commit3dc44aba71305cd9be8cba7703a96b6528f34169 (patch)
treedb047d06b94c106d70fa4e9521b31c76f9781675
parent82268e078d5326835faecdd683efe448c4981085 (diff)
downloadcpython-3dc44aba71305cd9be8cba7703a96b6528f34169.zip
cpython-3dc44aba71305cd9be8cba7703a96b6528f34169.tar.gz
cpython-3dc44aba71305cd9be8cba7703a96b6528f34169.tar.bz2
add debug, use waitpid
-rwxr-xr-xDemo/stdwin/jukebox.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/Demo/stdwin/jukebox.py b/Demo/stdwin/jukebox.py
index 377078c..e218e66 100755
--- a/Demo/stdwin/jukebox.py
+++ b/Demo/stdwin/jukebox.py
@@ -47,7 +47,7 @@ SFPLAY = '/usr/sbin/sfplay' # Sound playing program
class struct: pass # Class to define featureless structures
-G = struct() # oHlds writable global variables
+G = struct() # Holds writable global variables
# Main program
@@ -83,6 +83,10 @@ def main():
elif optname == '-t':
G.mode = optarg
#
+ if G.debug:
+ for name in G.__dict__.keys():
+ print 'G.' + name, '=', `G.__dict__[name]`
+ #
if not args:
args = [DEF_DB]
#
@@ -149,7 +153,7 @@ def killchild():
waitchild(0)
def waitchild(options):
- pid, sts = os.wait(G.busy, options)
+ pid, sts = os.waitpid(G.busy, options)
if pid == G.busy:
G.busy = 0
G.stop.enable(0)