diff --git a/src/command_line.py b/src/command_line.py index 92b6c49..94fbbbd 100644 --- a/src/command_line.py +++ b/src/command_line.py @@ -250,7 +250,7 @@ command_line = CommandLine() def print_options(): keys = options.keys() keys.sort() - import subprocess, threading + import subprocess for k in keys: description = options[k][1] p1 = subprocess.Popen(["fold", "-s", "-w", "40"],stdout=subprocess.PIPE,stdin=subprocess.PIPE) diff --git a/src/create_man.py b/src/create_man.py index 52f5816..cc8df59 100644 --- a/src/create_man.py +++ b/src/create_man.py @@ -139,14 +139,16 @@ def do_print_subroutines(sub): def run(): import parsed_text import os,sys - if os.fork() == 0: + pid1 = os.fork() + if pid1 == 0: for v in variables.values(): do_print(v) for s in subroutines.values(): do_print_subroutines(s) sys.exit(0) - if os.fork() == 0: + pid2 = os.fork() + if pid2 == 0: tags = [] l = variables.keys() file = open("irpf90_entities","w") @@ -169,6 +171,9 @@ def run(): file.close() sys.exit(0) + os.waitpid(pid1,0) + os.waitpid(pid2,0) + ###################################################################### if __name__ == '__main__': run() diff --git a/src/util.py b/src/util.py index 8511656..0c81577 100644 --- a/src/util.py +++ b/src/util.py @@ -100,7 +100,6 @@ def dimsize(x): buffer = x.split(':') if len(buffer) == 1: return x - buffer = map(strip,buffer) else: assert len(buffer) == 2 size = ""