Kaydet (Commit) 8d009973 authored tarafından Enrico Tröger's avatar Enrico Tröger

Fix crash when saving a file after setting encoding "None".


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1767 ea778897-0a13-0410-b9d1-a72fbfd435f5
üst b6291331
2007-07-31 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>
* po/Makefile.in.in: Removed.
* src/symbols.c:
Fix crash when saving a file after setting encoding "None".
2007-07-30 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
* src/tools.c, src/sciwrappers.c, src/callbacks.c, src/search.c:
......
......@@ -348,8 +348,11 @@ get_tag_list(gint idx, guint tag_types)
tag_names = NULL;
}
// do this comparison only once
if (utils_str_equal(doc_list[idx].encoding, "UTF-8")) doc_is_utf8 = TRUE;
// encodings_convert_to_utf8_from_charset() fails with charset "None", so skip conversion
// for None at this point completely
if (utils_str_equal(doc_list[idx].encoding, "UTF-8") ||
utils_str_equal(doc_list[idx].encoding, "None"))
doc_is_utf8 = TRUE;
for (i = 0; i < (doc_list[idx].tm_file)->tags_array->len; ++i)
{
......@@ -363,6 +366,9 @@ get_tag_list(gint idx, guint tag_types)
-1, doc_list[idx].encoding, TRUE);
else utf8_name = tag->name;
if (utf8_name == NULL)
continue;
symbol = g_new0(GeanySymbol, 1);
if ((tag->atts.entry.scope != NULL) && isalpha(tag->atts.entry.scope[0]))
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment