[anjuta] language-support-cpp-java: Don't call the expression parser when we have no filename
- From: Johannes Schmid <jhs src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [anjuta] language-support-cpp-java: Don't call the expression parser when we have no filename
- Date: Wed, 3 Mar 2010 10:40:09 +0000 (UTC)
commit 03d1715f057bb668a2ede6ce48dfcd28df885842
Author: Johannes Schmid <jhs idefix localdomain>
Date: Tue Mar 2 09:27:45 2010 +0100
language-support-cpp-java: Don't call the expression parser when we have no filename
This fixes the crash in bgo#608610
.../language-support-cpp-java/cpp-java-assist.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/plugins/language-support-cpp-java/cpp-java-assist.c b/plugins/language-support-cpp-java/cpp-java-assist.c
index 5e238ea..391c578 100644
--- a/plugins/language-support-cpp-java/cpp-java-assist.c
+++ b/plugins/language-support-cpp-java/cpp-java-assist.c
@@ -886,8 +886,13 @@ cpp_java_parse_expression (CppJavaAssist* assist, IAnjutaIterable* iter, IAnjuta
if (file != NULL)
{
filename = g_file_get_path (file);
+ g_object_unref (file);
+ }
+ else
+ {
+ g_free (stmt);
+ return NULL;
}
- g_object_unref (file);
}
start = ianjuta_editor_get_start_position (editor, NULL);
above_text = ianjuta_editor_get_text (editor, start, iter, NULL);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]