Changeset f3cb36b in sasmodels for sasmodels/kerneldll.py


Ignore:
Timestamp:
May 25, 2016 10:41:46 PM (6 years ago)
Author:
Brian Ben Maranville <brian.maranville@…>
Children:
7887cf4
Parents:
9b71c30
Message:

fix that works

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/kerneldll.py

    r9b71c30 rf3cb36b  
    122122    logging.info(command_str) 
    123123    try: 
    124         subprocess.check_output(command, shell=True, stderr=subprocess.STDOUT) 
     124        subprocess.check_output(command, shell=False, stderr=subprocess.STDOUT) 
    125125    except subprocess.CalledProcessError as exc: 
    126126        raise RuntimeError("compile failed.\n%s\n%s"%(command_str, exc.output)) 
     
    198198        source = generate.convert_type(source, dtype) 
    199199        fd, filename = tempfile.mkstemp(suffix=".c", prefix=tempfile_prefix) 
    200         with open(filename, "w") as file: 
     200        with os.fdopen(fd, "w") as file: 
    201201            file.write(source) 
    202         os.close(fd) 
    203202        compile(source=filename, output=dll) 
    204203        # comment the following to keep the generated c file 
Note: See TracChangeset for help on using the changeset viewer.