packages/utils/mc/patches/100-fix-missingsyntax.patch
olli bae28c11de mc: add a patch to fix the annoying error message about missing Syntax file (#2133)
git-svn-id: svn://svn.openwrt.org/openwrt/packages@8182 3c298f89-4303-0410-b956-a3cf2f4a3e73
2007-07-26 15:44:00 +00:00

20 lines
731 B
Diff

Index: mc-4.6.1/edit/syntax.c
===================================================================
--- mc-4.6.1.orig/edit/syntax.c 2007-07-26 17:35:14.000000000 +0200
+++ mc-4.6.1/edit/syntax.c 2007-07-26 17:35:14.000000000 +0200
@@ -1113,13 +1113,8 @@
f = catstrs (home_dir, SYNTAX_FILE, (char *) NULL);
r = edit_read_syntax_file (edit, names, f, edit ? edit->filename : 0,
get_first_editor_line (edit), type);
- if (r == -1) {
- edit_free_syntax_rules (edit);
- message (D_ERROR, _(" Load syntax file "),
- _(" Cannot open file %s \n %s "), f,
- unix_error_string (errno));
+ if (r == -1)
return;
- }
if (r) {
edit_free_syntax_rules (edit);
message (D_ERROR, _(" Load syntax file "),