* syntax.c (edit_read_syntax_file): Use system wide Syntax

Highlighting definitions' file if there is no users one.
This commit is contained in:
Andrew V. Samoilov 2002-03-25 07:52:53 +00:00
parent 8766ce3b02
commit 47f1ce66af
2 changed files with 12 additions and 6 deletions

View File

@ -1,3 +1,8 @@
2002-03-25 Andrew V. Samoilov <kai@cmail.ru>
* syntax.c (edit_read_syntax_file): Use system wide Syntax
Highlighting definitions' file if there is no users one.
2002-03-18 Pavel Roskin <proski@gnu.org>
* edit.h: Use eregex.h, not regex.h.

View File

@ -866,13 +866,14 @@ static int edit_read_syntax_file (WEdit * edit, char **names, char *syntax_file,
int count = 0;
char *lib_file;
lib_file = concat_dir_and_file (mc_home, "syntax" PATH_SEP_STR "Syntax");
check_for_default (lib_file, syntax_file);
g_free (lib_file);
f = fopen (syntax_file, "r");
if (!f)
return -1;
if (!f){
lib_file = concat_dir_and_file (mc_home, "syntax" PATH_SEP_STR "Syntax");
f = fopen (lib_file, "r");
g_free (lib_file);
if (!f)
return -1;
}
args[0] = 0;
for (;;) {
line++;