Mercurial > cpython-lru_cache-weakref
comparison Python/pythonrun.c @ 85420:ef889c3d5dc6
Issue #18571: Implementation of the PEP 446: file descriptors and file handles
are now created non-inheritable; add functions os.get/set_inheritable(),
os.get/set_handle_inheritable() and socket.socket.get/set_inheritable().
| author | Victor Stinner <victor.stinner@gmail.com> |
|---|---|
| date | Wed, 28 Aug 2013 00:53:59 +0200 |
| parents | df2fdd42b375 |
| children | 0424f4761500 |
comparison
equal
deleted
inserted
replaced
| 85419:0872257752c2 | 85420:ef889c3d5dc6 |
|---|---|
| 1452 if (maybe_pyc_file(fp, filename, ext, closeit)) { | 1452 if (maybe_pyc_file(fp, filename, ext, closeit)) { |
| 1453 FILE *pyc_fp; | 1453 FILE *pyc_fp; |
| 1454 /* Try to run a pyc file. First, re-open in binary */ | 1454 /* Try to run a pyc file. First, re-open in binary */ |
| 1455 if (closeit) | 1455 if (closeit) |
| 1456 fclose(fp); | 1456 fclose(fp); |
| 1457 if ((pyc_fp = fopen(filename, "rb")) == NULL) { | 1457 if ((pyc_fp = _Py_fopen(filename, "rb")) == NULL) { |
| 1458 fprintf(stderr, "python: Can't reopen .pyc file\n"); | 1458 fprintf(stderr, "python: Can't reopen .pyc file\n"); |
| 1459 goto done; | 1459 goto done; |
| 1460 } | 1460 } |
| 1461 /* Turn on optimization if a .pyo file is given */ | 1461 /* Turn on optimization if a .pyo file is given */ |
| 1462 if (strcmp(ext, ".pyo") == 0) | 1462 if (strcmp(ext, ".pyo") == 0) |
