Adds function char *ReadAnyTextFile(const char
*fileName) to file.c for loading files with 'foreign' line
breaks. Changes ImportPrefFile in preferences.c to use
it when loading prefs files.
OK, a whole new version here. Now handles setting imports, normal settings files, and macro loading.
All linebreak-conversion stuff is moved to utils/fileUtils.c, and a new function ReadAnyTextFile is added, for easy use at different locations.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
patch
Logged In: YES
user_id=119143
I get a funny warning which I can't handle at this time of
the day:
preferences.c: In function `ImportPrefFile':
preferences.c:1232: warning: assignment makes pointer from
integer without a cast
Line 1232 is at the beginning of ImportPrefFile():
if ((fileString = ReadAnyTextFile(filename)) != NULL)
Logged In: YES
user_id=82866
OK, a whole new version here. Now handles setting imports, normal settings files, and macro loading.
All linebreak-conversion stuff is moved to utils/fileUtils.c, and a new function ReadAnyTextFile is added, for easy use at different locations.
Updated patch