Commit e00637bd authored by Jack Jansen's avatar Jack Jansen

Removed extraneous fclose() in case of .pyc file argument

parent 234fd7e4
...@@ -202,7 +202,7 @@ run_script(fp, filename) ...@@ -202,7 +202,7 @@ run_script(fp, filename)
ext = filename + strlen(filename) - 4; ext = filename + strlen(filename) - 4;
if ( strcmp(ext, ".pyc") == 0 ) { if ( strcmp(ext, ".pyc") == 0 ) {
/* Try to run a pyc file. First, re-open in binary */ /* Try to run a pyc file. First, re-open in binary */
fclose(fp); /* Don't close, done in main: fclose(fp); */
if( (fp = fopen(filename, "rb")) == NULL ) { if( (fp = fopen(filename, "rb")) == NULL ) {
fprintf(stderr, "python: Can't reopen .pyc file\n"); fprintf(stderr, "python: Can't reopen .pyc file\n");
return -1; return -1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment