mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-08 20:41:59 +03:00
* ext.c (exec_extension): Don't create self-destructing scripts
for the viewer - remove those scripts manually after calling view(). This fixes the problem with double F8 in the viewer on parsed files. Reported by David Martin <dmartina@excite.com>
This commit is contained in:
parent
0ff23cc6a3
commit
3ee1c3b3f6
@ -1,11 +1,17 @@
|
||||
2002-10-30 Pavel Roskin <proski@gnu.org>
|
||||
|
||||
* ext.c (exec_extension): Don't create self-destructing scripts
|
||||
for the viewer - remove those scripts manually after calling
|
||||
view(). This fixes the problem with double F8 in the viewer on
|
||||
parsed files.
|
||||
Reported by David Martin <dmartina@excite.com>
|
||||
|
||||
* ext.c (exec_extension): Don't rely on working #! - explicitly
|
||||
run /bin/sh on the temporary script.
|
||||
|
||||
* mouse.h: Use definitions for GPM_B_DOWN and GPM_B_UP
|
||||
compatible with gpm-1.20.
|
||||
Reported by by David Martin <dmartina@excite.com>
|
||||
Reported by David Martin <dmartina@excite.com>
|
||||
|
||||
2002-10-29 Pavel Roskin <proski@gnu.org>
|
||||
|
||||
|
3
src/TODO
3
src/TODO
@ -12,9 +12,6 @@ security issues.
|
||||
Consider applying a patch from PLD to make M-o propagate the current
|
||||
directory to the other panel.
|
||||
|
||||
Pressing F8 twice in the viewer causes error messages if the file was
|
||||
preprocessed (i.e. gzipped files, manpages).
|
||||
|
||||
ncurses 5.2 turns off keypad under heavy load on xterm. Check if
|
||||
anything can be done about it.
|
||||
|
||||
|
17
src/ext.c
17
src/ext.c
@ -205,8 +205,15 @@ exec_extension (const char *filename, const char *data, int *move_dir,
|
||||
}
|
||||
} /* for */
|
||||
|
||||
/* Make sure that the file removes itself when it finishes */
|
||||
fprintf (cmd_file, "\n/bin/rm -f %s\n", file_name);
|
||||
/*
|
||||
* Make the script remove itself when it finishes.
|
||||
* Don't do it for the viewer - it may need to rerun the script,
|
||||
* so we clean up after calling view().
|
||||
*/
|
||||
if (!run_view) {
|
||||
fprintf (cmd_file, "\n/bin/rm -f %s\n", file_name);
|
||||
}
|
||||
|
||||
fclose (cmd_file);
|
||||
|
||||
if ((run_view && !written_nonspace) || is_cd) {
|
||||
@ -234,10 +241,12 @@ exec_extension (const char *filename, const char *data, int *move_dir,
|
||||
/* If we've written whitespace only, then just load filename
|
||||
* into view
|
||||
*/
|
||||
if (written_nonspace)
|
||||
if (written_nonspace) {
|
||||
view (cmd, filename, move_dir, start_line);
|
||||
else
|
||||
unlink (file_name);
|
||||
} else {
|
||||
view (0, filename, move_dir, start_line);
|
||||
}
|
||||
if (changed_hex_mode && !altered_hex_mode)
|
||||
default_hex_mode = def_hex_mode;
|
||||
if (changed_nroff_flag && !altered_nroff_flag)
|
||||
|
Loading…
Reference in New Issue
Block a user