[packages] mc: update to v4.6.2, update URLs, cleanup
[openwrt/svn-archive/archive.git] / utils / mc / patches / 100-fix-missingsyntax.patch
index 3e4f737e2edc11f1286572d52eb4c7cede7ea73c..88a78439a14c4af64a2914a1fc86c61bf40abf5c 100644 (file)
@@ -1,19 +1,14 @@
-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,
+--- a/edit/syntax.c
++++ b/edit/syntax.c
+@@ -1193,10 +1193,7 @@ edit_load_syntax (WEdit *edit, char ***p
+     r = edit_read_syntax_file (edit, pnames, f, edit ? edit->filename : 0,
                               get_first_editor_line (edit), type);
--    if (r == -1) {
+     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) {
++      /* missing syntax file */
+     } else if (r) {
        edit_free_syntax_rules (edit);
        message (D_ERROR, _(" Load syntax file "),